#include<stdio.h>
int main()
{
long long int n;
while(scanf("%lld",&n)!=EOF)
{
if((n&(n-1))==0)
printf("TAK\n");
else
printf("NIE\n");
}
return 0;
}
int main()
{
long long int n;
while(scanf("%lld",&n)!=EOF)
{
if((n&(n-1))==0)
printf("TAK\n");
else
printf("NIE\n");
}
return 0;
}
if((n&(n-1))==0)
ReplyDeletehow does this statement checks if n is a power of 2 ?