Given a number N, you need to find if N is fibonacci-prime number or not. A fibonacci-prime is any number that is both a prime and a fibonacci number.
The first line of the input contains a single integer T, denoting the number of test cases. Then T testcases follow. Each testcase contains a single line of input denoting the value of N.
For each testcase, print 1 if N is a fibonacci-prime; print 0 if N is not a fibonacci-prime.
If you have purchased any course from GeeksforGeeks then please ask your doubt on course discussion forum. You will get quick replies from GFG Moderators there.