What is wrong in the solution of this QUESTION ? # CKWLK

#include<iostream>
#include<cmath>
using namespace std;
int main()
{
	int t;
	cin>>t;
	while(t!=0)
	{
		long long int n;
		cin>>n;
		long long int temp;
		int count=0;
		while(n%10==0)
		{
			count++;
			n=n/10;
		}
		int flag=0;
	    for (int i =0 ; i < count ; i++)
	    {
	    	long long int power;
	    	power = pow(2,i);
	    	if(power==n)
	    		flag=1;
	    }
	    if (flag == 0)
	    	cout<<"No"<<endl;
	    else if (flag == 1)
	    	cout<<"Yes"<<endl;
		t--;
	}
	return 0;
}

Blockquote

Try i <= count
Hopefully it will work

Sudheera Y S
:slightly_smiling_face::smile: