Chromosome
At a biomedical research center, the technician must examine a string of chromosome to see if it matches a particular pattern. Each string consists of any uppercase alphabet (i.e., A, B, C, …, Z). Currently, the technician must find if the string exactly matches the following rules:
Starting with zero or exactly one alphabet from {A, B, C, D, E, F}
Following by at least one or more of alphabet A
Following by at least one or more alphabet F
Following by at least one or more alphabet C
Following by zero or exactly one alphabet from {A, B, C, D, E, F}
You job is to write a program that performs this check.
Input
First line of input is a number of test cases T ≤ 20. Each test case is a line contains only uppercase alphabet without any whitespace and at most 200 alphabets.
Output
For each test case, display "Infected!" in one line if that string matches the pattern described above. Otherwise, output "Good" in one line.
Note: Do not output the '"' symbol. It is used for clarification purpose.