import java.util.*;
class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System. in );
String[] arr = new String[0];
int repeat = sc.nextInt();
while (repeat>0) {
int x = sc.nextInt();
String tmp="";
if(x<60){
tmp="Fail";
}else{
tmp="Pass";
}
String[] dst = new String[arr.length+1];
System.arraycopy(arr, 0, dst, 0, arr.length);
dst[dst.length - 1] = tmp;
arr = dst;
repeat--;
}
sc.close();
for (int i = 0; i < arr.length; i++) {
System.out.println(arr[i]);
}
}
}