#include #define MAX 1000000+1 int a[MAX]; int main() { for (int n=1; n0) { if ( (a[nk] & a[n2k]) == a[nk] ) { v++; } nk -= 1; n2k -= 2; } printf ("%d %d\n", n, a[n] = v); } return 0; }