Porter de discoteca
Algunes discoteques tenen unes normes d'accés extranyes. Aquesta en concret té les següents:
Si ets menor d'edad no pots entrar
Els homes no poden portar arracades
S'ha d'anar ben vestit
Els que tenen la tarjeta VIP poden entrar, sense tenir en compte aquestes normes.
Es desitja implementar un sistema de control d'accés automàtic a la discoteca que autoritzi l'accès en base a aquestes regles. (Un sistema basat en el reconeixement d'imatges i NFC proporciona les dades d'entrada).
Input Format
L'entrada consta de 5 dades:
Un nombre enter indica l'edat
El sexe s'indica amb {home|dona}
Un booleà indica si porta arracades
Un booleà indica si va ben vestit
Un booleà indica si té tarjeta VIP
Constraints
No hi ha
Output Format
S'imprimirà "ENTRA" si el sistema autoritza l'accés i "NO ENTRA" en cas contrari.
Test Case 1
Input
17 home true true true
Output
ENTRA
Test Case 2
Input
17 home true true true
Output
ENTRA
Test Case 3
Input
17 home true true false
Output
NO ENTRA
Test Case 4
Hidden: this is a private test case!
Test Case 5
Hidden: this is a private test case!
Test Case 6
Hidden: this is a private test case!
Test Case 7
Input
17 home false true false
Output
NO ENTRA
Test Case 8
Hidden: this is a private test case!
Test Case 9
Input
17 home false false false
Output
NO ENTRA
Test Case 10
Hidden: this is a private test case!
Test Case 11
Input
17 dona true true false
Output
NO ENTRA
Test Case 12
Hidden: this is a private test case!
Test Case 13
Input
17 dona true false false
Output
NO ENTRA
Test Case 14
Hidden: this is a private test case!
Test Case 15
Input
17 dona false true false
Output
NO ENTRA
Test Case 16
Hidden: this is a private test case!
Test Case 17
Input
17 dona false false false
Output
NO ENTRA
Test Case 18
Hidden: this is a private test case!
Test Case 19
Input
18 home true true false
Output
NO ENTRA
Test Case 20
Hidden: this is a private test case!
Test Case 21
Hidden: this is a private test case!
Test Case 22
Hidden: this is a private test case!
Test Case 23
Hidden: this is a private test case!
Test Case 24
Hidden: this is a private test case!
Test Case 25
Hidden: this is a private test case!
Test Case 26
Hidden: this is a private test case!
Test Case 27
Hidden: this is a private test case!
Test Case 28
Hidden: this is a private test case!
Test Case 29
Hidden: this is a private test case!
Test Case 30
Hidden: this is a private test case!
Test Case 31
Hidden: this is a private test case!
Test Case 32
Hidden: this is a private test case!
Test Case 33
Input
18 dona false false false
Output
NO ENTRA
Test Case 34
Hidden: this is a private test case!
Test Case 35
Hidden: this is a private test case!
Test Case 36
Hidden: this is a private test case!
Test Case 37
Hidden: this is a private test case!
Test Case 38
Hidden: this is a private test case!
Test Case 39
Input
19 home false true false
Output
ENTRA
Test Case 40
Input
19 home false false true
Output
ENTRA
Test Case 41
Hidden: this is a private test case!
Test Case 42
Hidden: this is a private test case!
Test Case 43
Hidden: this is a private test case!
Test Case 44
Hidden: this is a private test case!
Test Case 45
Hidden: this is a private test case!
Test Case 46
Hidden: this is a private test case!
Test Case 47
Hidden: this is a private test case!
Test Case 48
Hidden: this is a private test case!
Test Case 49
Input
19 dona false false false
Output
NO ENTRA
CC BY-NC-SA 4.0