1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
n = int(input())
m=n//10
p = input()

points = 0

for i in range (10):
    newpoint = 1
    for j in range(1,m):
        if (p[i*m+j-1]=='N'):
            newpoint = 0
    points = points + newpoint

print(points)