Problem:


Score : 200 points

Problem Statement

In Japan, people make offerings called hina arare, colorful crackers, on March 3.

We have a bag that contains N hina arare. (From here, we call them arare.)

It is known that the bag either contains arare in three colors: pink, white and green, or contains arare in four colors: pink, white, green and yellow.

We have taken out the arare in the bag one by one, and the color of the i-th arare was S_i, where colors are represented as follows - pink: P, white: W, green: G, yellow: Y.

If the number of colors of the arare in the bag was three, print Three; if the number of colors was four, print Four.

Constraints

1 \leq N \leq 100

S_i is P, W, G or Y.

There always exist i, j and k such that S_i=P, S_j=W and S_k=G.

Input

Input is given from Standard Input in the following format:

N
S_1 S_2 ... S_N

Output

If the number of colors of the arare in the bag was three, print Three; if the number of colors was four, print Four.

Sample Input 1

6
G W Y P Y W

Sample Output 1

Four

The bag contained arare in four colors, so you should print Four.

Sample Input 2

9
G W W G P W P G G

Sample Output 2

Three

The bag contained arare in three colors, so you should print Three.

Sample Input 3

8
P Y W G Y W Y Y

Sample Output 3

Four



Sample input:
6
G W Y P Y W


Sample output:
Four

Submission status: Accepted

Solution code:
n=int(input())
s=list(input().split())
print('Three' if len(set(s))==3 else 'Four')

Submission status: Accepted

Solution code:
N = int(input())
S = input().split()
K = set(S)
k = list(K)
if len(k) == 3:
  print("Three")
elif len(k) == 4:
  print("Four")

Submission status: Accepted

Solution code:
from collections import Counter

n = int(input())
S = list(input().split())
c = Counter(S)
if len(c) == 4:
    print('Four')
else:
    print('Three')

Submission status: Accepted

Solution code:
N = int(input())
A = input().split()

if len(set(A)) <= 3:
    print("Three")
else:
    print("Four")

Submission status: Accepted

Solution code:
import sys

def solve():
    input = sys.stdin.readline
    N = int(input())
    S = set([str(i) for i in input().strip("\n").split()])
    if len(S) == 3: print("Three")
    else:print("Four")

    return 0

if __name__ == "__main__":
    solve()

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
n = int(input())
s = [str(i) for i in input().split()]

if len(set(s)) == 3:
    print("Three")
else:
    print("Four")

Submission status: Accepted

Solution code:
N = int(input())
l = list(input().split())
s = set(l)

if len(s)==3:
    print('Three')
else:
    print('Four')

Submission status: Accepted

Solution code:
n, *s = open(0).read().split()
if "Y" in s: print("Four")
else: print("Three")

Submission status: Accepted

Solution code:
N = int(input())
S = list(map(str,input().split()))

if len(set(S)) == 3:
    print("Three")
else:
    print("Four")

Submission status: Accepted

Solution code:

a = int(input())
l = list(map(str,input().split()))

s = len(set(l))
if s == 3:
    print('Three')
else:
    print('Four')

Submission status: Accepted

Solution code:
def main():
    N = int(input())
    A = [i for i in input().split()]
    ans = ["Three", "Four"]
    print(ans[0] if len(set(A)) == 3 else ans[1])


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
N = int(input())
S = set(input().split())
print('Four' if len(S)==4 else 'Three')

Submission status: Accepted

Solution code:
n=input()
s=len(set(list(map(str,input().split()))))
if s==3:
  print("Three")
else:
  print("Four")

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

N = int(input().strip())
S_list = input().rstrip().split()

x=set(S_list)
print( "Three" if len(x)==3 else "Four" )

Submission status: Accepted

Solution code:
_ = int(input())
s = input().split()
print('Four' if 'Y' in s else 'Three')

Submission status: Accepted

Solution code:
import numpy as np

N = int(input())

S = [str(_) for _ in input().split()]

Num = len(set(S))

if Num ==3:
    print('Three')
elif Num==4:
    print('Four')

Submission status: Accepted

Solution code:
n = int(input())
s = set(input().split())
a = {3:"Three",4:"Four"}
print(a[len(s)])

Submission status: Accepted

Solution code:
n = int(input())
S = list(map(str, input().split()))
S = set(S)
if len(S) == 3:
    print('Three')
elif len(S) == 4:
    print('Four')

Submission status: Accepted

Solution code:
n = int(input())
s = set(input().split())
if len(s) == 4:
    print("Four")
else:
    print("Three")

Submission status: Accepted

Solution code:
n = int(input())
s = list(input().split())
if len(set(s)) == 3:
  print('Three')
else:
  print('Four')

Submission status: Accepted

Solution code:
N = int(input())
A = list(input().split())
A = set(A)
print("Four" if len(A)==4 else "Three")

Submission status: Accepted

Solution code:
N = int(input())
S = set(input().split())


if len(S) == 3:
    print('Three')
else:
    print('Four')

Submission status: Accepted

Solution code:
n = int(input())
s = [_ for _ in input().split()]
if not 'Y' in s:
    print('Three')
else:
    print('Four')

Submission status: Accepted

Solution code:
from collections import Counter
n = input()
c = Counter(input().split())
print('Three' if len(c) == 3 else 'Four')

Submission status: Accepted

Solution code:
n = int(input())
s = list(input().split())
if len(set(s)) == 3:
    print("Three")
elif len(set(s)) == 4:
    print("Four")

Submission status: Accepted

Solution code:
N = int(input())
S = input().split()
K = set(S)
p = list(K)
if len(p) == 3:
  print("Three")
elif len(p) == 4:
  print("Four")

Submission status: Accepted

Solution code:
N = int(input())
S = list(input().split())

if 'Y' in S:
  ans = 'Four'
else:
  ans = 'Three'
print(ans)

Submission status: Accepted

Solution code:
import collections
N = int(input())
hinaarare = input().split()

c = collections.Counter(hinaarare)

if len(c) == 3:
    print('Three')
else :
    print('Four')

Submission status: Accepted

Solution code:
input()
a=input().split()
b=set(a)
if len(b)==4:
  print("Four")
else:
  print("Three")

Submission status: Accepted

Solution code:
input()
print("Three" if len(set(input().split())) < 4 else "Four")

Submission status: Accepted

Solution code:
N = int(input())
S_li = list(input().split())
types = len(list(set(S_li)))
print("Three" if types == 3 else "Four")

Submission status: Accepted

Solution code:
n=int(input())
s=list(input().split())
if "Y" in s:
    print("Four")
else:
    print("Three")

Submission status: Accepted

Solution code:
N=int(input())
S=list(map(str,input().split()))
if len(set(S))==4:
	print("Four")
else:
	print("Three")

Submission status: Accepted

Solution code:
n = int(input())
sl = list(map(str, input().split()))
d = set()
for s in sl:
    d.add(s)

if len(d) == 3:
    print('Three')
else:
    print('Four')

Submission status: Accepted

Solution code:
N=int(input())
S=input().split()

f=0
for i in range(N):
    if S[i]=="Y":
        f=1
        
if f==1:
    print("Four")
else:
    print("Three")

Submission status: Accepted

Solution code:
n=int(input())
s=list(input().split())

s1=set(s)
if len(s1)==4:
    print("Four")
if len(s1)==3:
    print("Three")

Submission status: Accepted

Solution code:
n = int(input())
a = set(map(str, input().split()))

if len(a) == 3:
	print("Three")
else:
	print("Four")

Submission status: Accepted

Solution code:
n = int(input())
s = map(str, input().split())

if "Y" in s:
  print("Four")
else:
  print("Three")

Submission status: Accepted

Solution code:
n = int(input())
s = input().split()
if len(set(s)) == 3:
    print("Three")
else:
    print("Four")

Submission status: Accepted

Solution code:
n = int(input())
A = list(input().split())

if len(set(A)) == 3:
    print("Three")
else:
    print("Four")

Submission status: Accepted

Solution code:
N = int(input())
S = set(map(str, input().split()))
if len(S) == 3:
    print('Three')
elif len(S) == 4:
    print('Four')

Submission status: Accepted

Solution code:
def main():
    num = int(input())
    colors = list(input().split(" "))
    for color in colors:
        if color == "Y":
            print("Four")
            break
    else:
        print("Three")


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
n = int(input())
s = list(map(str,input().split()))
length = len(set(s))
if length==3: print('Three')
elif length==4: print('Four')

Submission status: Accepted

Solution code:
N = int(input())
S = input().split()
if 'Y' in S:
  print('Four')
else:
  print('Three')

Submission status: Accepted

Solution code:
def main():
    n=int(input())
    ss=list(input().split())
    print('Four' if 'Y' in ss else 'Three')

main()

Submission status: Accepted

Solution code:
n = int(input())
#l = list(map(int, input().split()))
l = input()
#print(l)
if 'Y' in l:
    print('Four')
else:
    print('Three')

Submission status: Accepted

Solution code:
n = int(input())
l = list(input().split())
if 'Y' in l:
    print("Four")
else:
    print("Three")

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
# -*- coding: utf-8 -*-


def main():
    N = int(input())
    S = input().split()
    print('Three' if len(set(S)) == 3 else 'Four')


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
N = int(input())
s = set(map(str, input().split()))

if len(s)==3:
    print('Three')
else:
    print('Four')

Submission status: Accepted

Solution code:
N = int(input())
S = list(input().split())
flg = True

for s in S:
    if s == 'Y':
        print('Four')
        flg = False
        break

if flg == True:
    print('Three')

Submission status: Accepted

Solution code:
n = input()
b = raw_input().split()
a = []
for i in b:
    if i not in a:
        a.append(i)
if len(a) == 3:
    print "Three"
else:
    print "Four"

Submission status: Accepted

Solution code:
n = input()
arr = raw_input().split()
c = []
for k in arr:
    if k not in c:
        c.append(k)
if len(c) == 3:
    print "Three"
else:
    print "Four"

Submission status: Accepted

Solution code:
N = int(input())
Slist = input().split()
isFour = False

for n in range(N):
    if Slist[n] == "Y":
        isFour = True

if isFour:
    print("Four")
else:
    print("Three")

Submission status: Accepted

Solution code:
_ = input()

hina_arares = input().split()
hina_arare_type = set(hina_arares)

print("Three" if len(hina_arare_type) == 3 else "Four")

Submission status: Accepted

Solution code:
input()
s = input().split()

if s.count("Y") == 0:
  print("Three")
else:
  print("Four")

Submission status: Accepted

Solution code:
n=input()
if len(set(list(input().split())))==3:print("Three")
else:print("Four")

Submission status: Accepted

Solution code:
n = int(input())
s = list(map(str, input().split()))

count = [0] * 4

for i in range(n):
    if(s[i] == 'G'):
        count[0] = 1
    elif(s[i] == 'W'):
        count[1] = 1
    elif(s[i] == 'P'):
        count[2] = 1
    elif(s[i] == 'Y'):
        count[3] = 1

total = 0
for i in range(4):
    total += count[i]

if(total == 3):
    print('Three')
elif(total == 4):
    print('Four')

Submission status: Accepted

Solution code:
n=int(input())
*s,=list(input().split())
ans=len(set(s))
if ans == 3:
    print("Three")
elif ans == 4:
    print("Four")
else:
    print("NA")

Submission status: Accepted

Solution code:
n = int(input())
s = list(input().split())
if "G" in s and "P" in s and "W" in s and "Y" in s:
    print("Four")
elif "G" in s and "P" in s and "W" in s:
    print("Three")

Submission status: Accepted

Solution code:
n = int(input())
s = list(map(str, input().split()))
ss = set(s)
if len(ss) == 3:
	print ("Three")
else:
	print ("Four")

Submission status: Accepted

Solution code:
n = int(input())
s = input().split()

arare = 0
if "P" in s:
    arare += 1
if "W" in s:
    arare += 1
if "G" in s:
    arare += 1
if "Y" in s:
    arare += 1

if arare == 3:
    print("Three")
else:
    print("Four")

Submission status: Accepted

Solution code:
input();print('TFhoruere'['Y' in input()::2])

Submission status: Accepted

Solution code:
input();print('TFhoruere'[len(set(input().split()))>3::2])

Submission status: Accepted

Solution code:
n=int(input())
s=set(map(str,input().split()))
n=len(s)
if n==3:
  print("Three")
if n==4:
  print("Four")

Submission status: Accepted

Solution code:
n = int(input())
s = [i for i in input().split()]

print("Four" if "Y" in s else "Three")

Submission status: Accepted

Solution code:
n=int(input())
s=input().split()

dic={}

flag=False

for ss in s:
    if ss not in dic:
        dic[ss] = 1

if len(dic) == 4:
    print("Four")
else:
    print("Three")

Submission status: Accepted

Solution code:
n = int(input())
s = set(input().split())
if (len(s)) == 3:
    print("Three")
else:
    print("Four")

Submission status: Accepted

Solution code:
n=input()
print("Four" if len(set(map(str,input().split())))==4 else "Three")

Submission status: Accepted

Solution code:
from collections import Counter
n = int(input())
A = input().split(' ')

a = Counter(A)
if len(a)==4:
    print('Four')
else:
    print('Three')

Submission status: Accepted

Solution code:
INT = lambda: int(input())
INTM = lambda: map(int,input().split())
STRM = lambda: map(str,input().split())
STR = lambda: str(input())
LIST = lambda: list(map(int,input().split()))
LISTS = lambda: list(map(str,input().split()))
def do():
    n=INT()
    s=LISTS()
    if 'Y' in s:
        print('Four')
    else:
        print('Three')
if __name__ == '__main__':
    do()

Submission status: Accepted

Solution code:
n = int(input())

S = list(input().split())

S = set(S)

if len(S) == 3:
    print('Three')
else:
    print('Four')

Submission status: Accepted

Solution code:
N = int(input())
S = input().split()
S = set(S)
print("Three" if len(S) == 3 else 'Four')

Submission status: Accepted

Solution code:
N = int(input())
S = list(input().split())
flag = True
for i in range(N):
    if S[i]=="Y":
        flag=False
if flag:
    print("Three")
else:
    print("Four")

Submission status: Accepted

Solution code:
n = int(input())
s = list(map(str,input().split()))

arr = [0] * 4
for i in range(n):
    if s[i] == 'P':
        arr[0] = 1
    elif s[i] == 'W':
        arr[1] = 1
    elif s[i] == 'G':
        arr[2] = 1
    elif s[i] == 'Y':
        arr[3] = 1

if sum(arr) == 3:
    print('Three')
else:
    print('Four')

Submission status: Accepted

Solution code:
n=int(input())
s=list(map(str, input().split()))
s_new=''.join(s)
if 'Y' in s_new:
    print('Four')
else:
    print('Three')

Submission status: Accepted

Solution code:
n = int(input())
s = input().split()

if(s.count("Y") > 0):
    print("Four")
else:
    print("Three")

Submission status: Accepted

Solution code:
n=int(input())
s=list(input().split())
if "Y" in s:
	print("Four")
else:
	print("Three")

Submission status: Accepted

Solution code:
n = int(input())
l = list(input().split())
print("Four" if "Y" in l else "Three")

Submission status: Accepted

Solution code:
n = int(input())
s = input().split()

for i in s:
  if(i == 'Y'):
    print('Four')
    exit()
print('Three')

Submission status: Accepted

Solution code:
import math
import sys
from functools import reduce
input = sys.stdin.readline

def main():
    input()
    print("Four" if "Y" in input() else "Three")

main()

Submission status: Accepted

Solution code:
N=int(input())
S=input().split()
if len(set(S))==3:
    print("Three")
elif len(set(S))==4:
    print("Four")

Submission status: Accepted

Solution code:
n=int(input())
a=input().split()
print('Four' if 'Y' in a else 'Three')

Submission status: Accepted

Solution code:
"""
author : halo2halo
date : 24, Jan, 2020
"""

import sys

# import itertools
# import numpy as np

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
sys.setrecursionlimit(10 ** 7)

A = int(readline())
S = set(readline().decode().split())

print('Four' if len(S) == 4 else 'Three')

Submission status: Accepted

Solution code:
input()
l=map(str,input().split())
print("Three" if len(set(l)) == 3 else "Four")

Submission status: Accepted

Solution code:
n = int(input())
c = list(map(str, input().split()))
print('Three' if len(set(c))==3 else 'Four')

Submission status: Accepted

Solution code:
n = int(input())
flag = False
s = input().split(" ")
for c in s:
  if(c == "Y"):
    flag = True

if(flag):
  print("Four")
else:
  print("Three")

Submission status: Accepted

Solution code:
# coding: utf-8
# Your code here!
N=int(input())
S=list(map(str,input().split()))
if len(set(S))==3:
    print('Three')
else:
    print('Four')

Submission status: Accepted

Solution code:
N = int(input())
list=list(map(str, input().split()))
for i in list:
    if i == "Y":
        print("Four")
        break
else:
    print("Three")

Submission status: Accepted

Solution code:
N = int(input())
L = list(input().split())
n = 3
for i in range (N):
  if L[i] == "Y":
    n = 4
    
if n == 4:
  print("Four")
if n == 3:
  print("Three")

Submission status: Accepted

Solution code:
n=input()
if len(set(list(input().split()))) == 3:print("Three")
else:print("Four")

Submission status: Accepted

Solution code:
_=input()
x=len(set(input().split()))
if x==3:
  print("Three")
else:
  print("Four")

Submission status: Accepted

Solution code:
int(input())
b = ["One","Two","Three","Four"]
a = list(map(str,input().split(" ")))
print(b[len(set(a))-1])

Submission status: Accepted

Solution code:
N = int(input())
S = set(map(str,input().split()))
if len(S) == 3:
  print("Three")
else:
  print("Four")

Submission status: Accepted

Solution code:
input();print("TFhoruere"["Y" in input()::2])

Submission status: Accepted

Solution code:
n = int(input())
s = list(map(str, input().split()))
if len(set(s)) == 3:
    print("Three")
else:
    print("Four")

Submission status: Accepted

Solution code:
N = int(input())
S = input().split()

color_dict = {}

for i in S:
  if i in color_dict:
    color_dict[i] += 1
  else:
    color_dict[i] = 1

if len(color_dict.keys()) == 4:
  ans = "Four"
else:
  ans = "Three"
print(ans)

Submission status: Accepted

Solution code:
n = int(input())
lst1 = list(input().split())

lst1 = list(set(lst1))

if len(lst1) == 4:
    print("Four")
else:
    print('Three')

Submission status: Accepted

Solution code:
n = int(input())
hList = set(input().split())

if len(hList) == 3:
  print("Three")
else:
  print("Four")

Submission status: Accepted

Solution code:


import numpy as np

input()
s=input()
if(s.count("Y")):
    print("Four")
else:print("Three")

Submission status: Accepted

Solution code:
n=int(input())
a=list(set(map(str,input().split())))
if len(a)==3:
  print('Three')
else:
  print('Four')

Submission status: Accepted

Solution code:
N = int(input())
s = input().split()

if len(set(s)) == 4:
    print("Four")
else:
    print("Three")

Submission status: Accepted

Solution code:
n = int(input())
S = list(input())

if 'Y' in S:
    print('Four')
else:
    print('Three')

Submission status: Accepted

Solution code:
N = int(input())
colors = set(input().split())

if len(colors) == 3:
    print('Three')
else:
    print('Four')

Submission status: Accepted

Solution code:
n=int(input())
s=list(map(str,input().split()))
if "P" in s and "W" in s and "G" in s and "Y" in s:
    print("Four")
else:
    print("Three")

Submission status: Accepted

Solution code:
n = int(input())
s = [x for x in input().split()]

c = len(set(s))
if (c == 4):
   print('Four')
else:
   print('Three')

Submission status: Accepted

Solution code:
n = int(input())
h = input().split()

if "P" and "W" and "G" and "Y" in h:
  print("Four")
elif "P" and "W" and "G" in h:
  print("Three")

Submission status: Accepted

Solution code:
N = int(input())
S = input().split()
ans = "Three"
for i in range(N) :
    if S[i] == 'Y' :
        ans = "Four"
        break
print(ans)

Submission status: Accepted

Solution code:
n = int(input())
s = input().split()
print('Four') if s.count('Y') else print('Three')

Submission status: Accepted

Solution code:
N=int(input())
l=list(map(str,input().split()))
ans="Three"
for a in l:
  if a=="Y":
    ans="Four"
print(ans)

Submission status: Accepted

Solution code:
n = int(input())

s = list(input().split())

if 'Y' in s:
    print('Four')
else:
    print('Three')

Submission status: Accepted

Solution code:
input()
s=input()
if 'Y'in s:
  print('Four')
else:
  print('Three')

Submission status: Accepted

Solution code:
N = int(input())
S = list(map(str, input().split()))

if 'Y' in S:
	print('Four')
else:
	print('Three')

Submission status: Accepted

Solution code:
n = int(input())
s = input().split()
if 'Y' in s:
  print('Four')
else:
  print('Three')

Submission status: Accepted

Solution code:
n = int(input())
arare = len(set(map(str, input().split())))
if arare == 4:
  print("Four")
elif arare == 3:
  print("Three")

Submission status: Accepted

Solution code:
N=int(input())//3
A = set(input().split())
if 'Y' in A:
  print('Four')
else:
  print('Three')

Submission status: Accepted

Solution code:
n = int(input())
s = list(input().split())

if len(set(s)) == 3:
  print("Three")
else:
  print("Four")

Submission status: Accepted

Solution code:
n=input()
s=input().split()
print('Three' if 'Y' not in s else 'Four')

Submission status: Accepted

Solution code:
n = int(input())
s = set(input().split())

if len(s) == 3:
    print("Three")
else:
    print("Four")

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
n=int(input())
s=list(map(str,input().split()))
from collections import Counter
a=Counter(s)
print("Four" if len(a)==4 else "Three")

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
N = int(input())
S = input().rstrip().split()
from collections import Counter
c = Counter(S)
if len(c.keys()) == 4:
    print("Four")
else:
    print("Three")

Submission status: Accepted

Solution code:
N = int(input())
S = input()
print("Four" if 'Y' in S else "Three")

Submission status: Accepted

Solution code:
n = int(input())
s = input().split()
print('Three' if len(set(s)) == 3 else 'Four')

Submission status: Accepted

Solution code:
n = int(input())
li = list(input().split())
y = 'Y'
if y in li:
  print('Four')
else:
  print('Three')

Submission status: Accepted

Solution code:
# -coding: utf-8 -

n = int(input())
s = input().split()

isFour = False
for i in s:
    if i == "Y":
        isFour = True

if isFour:
    print("Four")
else:
    print("Three")

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
 
import math
import itertools
import sys
import copy
 
# 入力
#A, B, C, D = map(int, input().split())
#L = list(map(int, input().split()))
N = int(input())
S = list(map(str, input().split()))

for i in range(N) :
  if S[i] == "Y" :
    print ("Four")
    exit()

print ("Three")

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
N = int(input())
s = [str(i) for i in input().split()] 

tmp = 0
for i in range(N):
    if s[i] == 'Y':
        tmp += 1
if tmp == 0:
    print("Three")
else:
    print("Four")

Submission status: Accepted

Solution code:

n = int(input())
s = list(map(str,input().split()))
status = 0

for i in range(n):
    if s[i] == "Y":
        print("Four")
        status = 1
        break

if status == 0:
    print("Three")

Submission status: Accepted

Solution code:
input()
a = input().split()
print('Four' if len(set(a)) == 4 else 'Three')

Submission status: Accepted

Solution code:
from collections import Counter
N = int(input())
S = [i for i in input().split()]
c = Counter(S)
print("Four" if len(dict(c)) == 4 else "Three")

Submission status: Accepted

Solution code:
n = int(input())
s = set(map(str, input().split()))
if len(s) == 3:
    print("Three")
else:
    print("Four")

Submission status: Accepted

Solution code:
n = int(input())
s = list(input().split())
st = set()
for i in s:
    st.add(i)
print('Three' if len(st)==3 else 'Four')

Submission status: Accepted

Solution code:
n = int(input())
s = list(map(str,input().split()))

if 'Y' in s:
    print('Four')
else:
    print('Three')

Submission status: Accepted

Solution code:
n = int(input())
s = input()
S = list(s)
if 'Y' in S:
    print('Four')
else:
    print('Three')

Submission status: Accepted

Solution code:
input()
l=[i for i in input().split()]
print("Four" if "Y" in l else "Three")

Submission status: Accepted

Solution code:
n = int(input())
s = [i for i in input().split()]

if "Y" in s:
    ans = "Four"
else:
    ans = "Three"

print(ans)

Submission status: Accepted

Solution code:
coun=0
n=int(input())
e=0
co=['G','Y','P','W']

l=input()
l=l.split(' ')
for i in range(4):
    d=l.count(co[i])
    if d==0:
        e+=1
if e==1:
    print("Three")
else :
    print("Four")

Submission status: Accepted

Solution code:
n=int(input())
s=input().split()
if s.count('Y')==0:
    print('Three')
else:
    print('Four')

Submission status: Accepted

Solution code:
n=int(input())
s=list(input().split())
if('Y' in s):
	print("Four")
else:
	print("Three")

Submission status: Accepted

Solution code:
n = int(input())
s = map(str, input().split())

if 'Y' in s:
    print('Four')
else:
    print('Three')

Submission status: Accepted

Solution code:
import sys

N = int(input())

*S, = list(input())


for s in S:
    if s=="Y":
        print("Four")
        sys.exit()

print("Three")

Submission status: Accepted

Solution code:

n=input()
S=input()
print("Four" if "Y" in S else "Three")

Submission status: Accepted

Solution code:
n=int(input())
s=input().split()

se=set(s)
if len(se)==3:
    print("Three")
else:
    print("Four")

Submission status: Accepted

Solution code:
n=int(input())
S=list(input().split())
print("Four" if "Y" in S else "Three")

Submission status: Accepted

Solution code:
N = int(input())
S_L = [i for i in input().split(" ")]
if len(set(S_L)) == 4:
    print("Four")
else:
    print("Three")

Submission status: Accepted

Solution code:
import sys

n, *s = sys.stdin.read().split()

def main():
    return 'Four' if len(set(s)) == 4 else 'Three'

if __name__ == '__main__':
    ans = main()
    print(ans)

Submission status: Accepted

Solution code:
N = int(input())
S = input().split()

print("Three" if len(set(S))==3 else "Four")

Submission status: Accepted

Solution code:
N = int(input())

if len(set(input().split())) == 3:
    print('Three')
else:
    print('Four')

Submission status: Accepted

Solution code:
n = int(input())
s = input()
if 'Y' in s:
    print('Four')
else:
    print('Three')

Submission status: Accepted

Solution code:
N = int(input())
Ss = list(input().split())
n = len(set(Ss))
if n == 3:
    print("Three")
else:
    print("Four")

Submission status: Accepted

Solution code:
a,b=open(0)
print(("Three","Four")["Y" in b])

Submission status: Accepted

Solution code:
import sys
n = int(input())
s = set(map(str, sys.stdin.readline().split()))

if len(s) == 4:
    print("Four")
else:
    print("Three")

Submission status: Accepted

Solution code:
N = int(input())
M = list(map(str,input().split()))

color = ["G","W","Y","P"]
tmp = 0
for i in color:
  if M.count(i) == 0:
    tmp += 1
if tmp == 0:
  print("Four")
else:
  print("Three")

Submission status: Accepted

Solution code:
a=int(input())
b=set(input().split())
if len(b)==3:
  print("Three")
else:
  print("Four")

Submission status: Accepted

Solution code:
N = int(input())
s = list(map(str, input().split()))
type = 0
flag = {'P':0,'W':0,'G':0,'Y':0}
for i in range(N):
	if(flag[s[i]] == 0):
		flag[s[i]]+=1
		type+=1
if(type==3):
	print("Three")
else:
	print("Four")

Submission status: Accepted

Solution code:
n = int(input())
s = list(input().split())

for i in range(n):
    if s[i] == "Y":
        print("Four")
        break
    elif i == n-1:
        print("Three")

Submission status: Accepted

Solution code:
N = int(input())
bag = list(map(str,input().split()))

if "Y" in bag:
  print("Four")
else:
  print("Three")

Submission status: Accepted

Solution code:
N = int(input())
A = list(map(str, input().split()))

Hina = ["P","W","G","Y"]

Pink = A.count("P")
White = A.count("W")
Green  = A.count("G")
Yello = A.count("Y")

if Yello != 0:
    print("Four")
else:
    print("Three")

Submission status: Accepted

Solution code:
n = int(input())
li = []
count =0

liste = [x for x in input().split()]
temp = []

for i in range(len(liste)):
    if liste[i] not in temp:
        temp.append(liste[i])

if len(temp)==3:
    print("Three")

else:
    print("Four")

Submission status: Accepted

Solution code:
N=int(input())
S=list(map(str,input().split()))
print("Four" if ("P" in S)*("W" in S)*("G" in S)*("Y" in S) else "Three")

Submission status: Accepted

Solution code:
#coding:utf-8
n = int(input())
s = list(map(str, input().split()))

#すでに中身はPWGかPWGYのどちらかであると分かっているので、Yの数のみで場合分け
if s.count('Y') >= 1:
    print('Four')
else:
    print('Three')

Submission status: Accepted

Solution code:
N = int(input())
S = list(input().split())
print("Four" if sum([1 for s in S if s == 'Y']) > 0 else "Three")

Submission status: Accepted

Solution code:
n=int(input())
s=set([i for i in input().split()])

if len(s)==3:
    print("Three")
else:
    print("Four")

Submission status: Accepted

Solution code:
n=int(input())
A=list(input().split())
if 'Y' in A:
  print('Four')
else:
  print('Three')

Submission status: Accepted

Solution code:
n=int(input())
s=list(map(str,input().split()))
if 'Y' in s:
    print('Four')
else:
    print('Three')

Submission status: Accepted

Solution code:
n = int(input())
s = input().split()
if s.count('Y') > 0:
    print('Four')
else:
    print('Three')

Submission status: Accepted

Solution code:
n=int(input())
h=list(input().split())
if len(list(set(h)))==3:
  print("Three")
else:
  print("Four")

Submission status: Accepted

Solution code:
N=int(input())
x=list(map(str,input().split()))
ans=len(list(set(x)))
if ans==3:
  print("Three")
else:
  print("Four")

Submission status: Accepted

Solution code:
n = int(input())
a = set(list(map(str, input().split())))
print("Four" if len(a) == 4 else "Three")

Submission status: Accepted

Solution code:
n = int(input())
S = list(input().split())
if len(set(S)) == 3:
  print("Three")
else:
  print("Four")

Submission status: Accepted

Solution code:
N = int(input())
lst = list(map(str, input().split()))
if 'Y' in lst:
  print('Four')
else:
  print('Three')

Submission status: Accepted

Solution code:
n=int(input())
l=set(map(str,input().split()))
if len(l)==3:
    print("Three")
else:
    print("Four")

Submission status: Accepted

Solution code:
n = int(input())
ls_s = list(map(str, input().split()))

if ("P" in ls_s) and ("W" in ls_s) and ("G" in ls_s) and ("Y" in ls_s):
    print("Four")
else:
    print("Three")

Submission status: Accepted

Solution code:
_ = input()
lst = [i for i in input().split()]

print('Three' if len(set(lst)) == 3 else 'Four')

Submission status: Accepted

Solution code:
n = int(input())
S = list(map(str, input().split()))

Color = ['P', 'W', 'G', 'Y']

count = 0

for c in Color:
    if c in S:
        count += 1

if count == 3:
    ans = 'Three'
elif count == 4:
    ans = 'Four'

print(ans)

Submission status: Accepted

Solution code:
N = int(input())
A = list(map(str, input().split()))
print('Three'if len(set(A))==3 else 'Four')

Submission status: Accepted

Solution code:
_ = input()
A = list(input())
print("Four" if "Y" in A else "Three")

Submission status: Accepted

Solution code:
n = int(input())

s_list = list(input().split())
s_set = set(s_list)
answer = len(list(s_set))
print('Four' if answer == 4 else 'Three')

Submission status: Accepted

Solution code:
N=int(input())
S = list(input().split())

if len(set(S))==3:
    print('Three')
else:
    print('Four')