When taking his computer science exam, economics student Ivan Hrivniov encountered a question asking him to determine if a given binary number is divisible by 3, 5, or 15. Please assist Ivan with this task.
The input consists of a single positive integer N, presented in binary form without any leading zeros. The binary number contains no more than 10,000 digits.
If the number is divisible only by 3, print "FIRST". If it is divisible only by 5, print "SECOND". If it is divisible by 15, print "BOTH". If the number is not divisible by any of these, print "NONE". All outputs should be in uppercase and without quotes.
Example 1