// editor3
#include<stdio.h>
#include<stdlib.h>
#include<string.h>


typedef struct HashNode {
    float amount;
    struct HashNode *next;
} HashNode;

HashNode *hashTable[SIZE] ;
int hashFunction(float amount) {
    int key = (int)(amount * 100);
    if (key < 0) key = -key;
    return key % SIZE;
}
void processTransaction(float amount) {
    int index = hashFunction(amount);
    HashNode *temp = hashTable[index];
    
    while (temp != NULL) {
        if (temp->amount == amount) {
            printf("FRAUD DETECTED\n");
            return;
        }
        temp = temp->next;
    }
    HashNode *newNode = (HashNode *)malloc(sizeof(HashNode));
    newNode->amount = amount;
    newNode->next = hashTable[index];
    hashTable[index] = newNode;
    
    printf("NO FRAUD\n");
}
int main(){
    int n;
    
    if (scanf("%d", &n) !=1){
        printf("Invalid input\n");
        return 0;
    }
    for (int i = 0; i < n; i++) {
        float amount;
        if (scanf("%f", &amount) !=1) {
            printf("Invalid input\n");
            return 0;
        }
        processTransaction(amount);
    }
    return 0;
}