When Serezha was three years old, he was given a set of cards with letters for his birthday. They were arranged into words in the way which formed the boy's mother favorite number in binary notation. Serezha started playing with them immediately and shuffled them because he wasn't yet able to read. His father decided to rearrange them. Help him restore the original number, on condition that it was the maximum possible one. 


-----Input-----

The first line contains a single integer $n$ ($1 \leqslant n \leqslant 10^5$) — the length of the string. The second line contains a string consisting of English lowercase letters: 'z', 'e', 'r', 'o' and 'n'.

It is guaranteed that it is possible to rearrange the letters in such a way that they form a sequence of words, each being either "zero" which corresponds to the digit $0$ or "one" which corresponds to the digit $1$.


-----Output-----

Print the maximum possible number in binary notation. Print binary digits separated by a space. The leading zeroes are allowed.


-----Examples-----
Input
4
ezor

Output
0 

Input
10
nznooeeoer

Output
1 1 0 



-----Note-----

In the first example, the correct initial ordering is "zero".

In the second example, the correct initial ordering is "oneonezero".

Difficulty: competition

Starter code:

Solutions:
def main():
    import sys
    input = sys.stdin.readline
    
    n = int(input())
    arr = input()
    
    one = arr.count('n')
    zero = arr.count('z')
    
    ans = [1] * one + [0] * zero
    
    print(*ans)
    
    return 0

main()


n = int(input())
s = input()
ones = 0
for i in s:
	if i == 'n':
		ones += 1
for i in range(ones):
	print(1, end = " ")
for j in range((n-ones*3)//4):
	print(0, end = " ")

import sys

def main():
	n = int(sys.stdin.readline())
	s = sys.stdin.readline()
	x = s.count('z')
	y = (n - 4 * x) // 3
	for i in range(y):
		print(1, end=' ')
	for i in range(x):
		print(0, end=' ')
	
def __starting_point():
	main()

__starting_point()

#!usr/bin/env python3
from collections import defaultdict,deque
from heapq import heappush, heappop
import sys
import math
import bisect
def LI(): return [int(x) for x in sys.stdin.readline().split()]
def I(): return int(sys.stdin.readline())
def LS():return [list(x) for x in sys.stdin.readline().split()]
def S():
    res = list(sys.stdin.readline())
    if res[-1] == "\n":
        return res[:-1]
    return res
def IR(n):
    return [I() for i in range(n)]
def LIR(n):
    return [LI() for i in range(n)]
def SR(n):
    return [S() for i in range(n)]
def LSR(n):
    return [LS() for i in range(n)]

sys.setrecursionlimit(1000000)
mod = 1000000007

#A
def A():
    n = I()
    s = S()
    d = defaultdict(lambda : 0)
    for i in s:
        d[i] += 1
    ans = [1]*d["n"]
    d["o"] -= d["n"]
    ans += [0]*d["o"]
    print(*ans) 
    return

#B
def B():

    return

#C
def C():

    return

#D
def D():

    return

#E
def E():

    return

#F
def F():

    return

#G
def G():

    return


#Solve
def __starting_point():
    A()

__starting_point()

kf = int(input())
s = input()
z = 0
e = 0
r = 0
o = 0
n = 0
for i in s:
    if i == 'z':
        z += 1
    elif i == 'e':
        e += 1
    elif i == 'r':
        r += 1
    elif i == 'o':
        o += 1
    else:
        n += 1
x = min(o, n, e)
o -= x
n -= x
e -= x
print('1 ' * x + '0 ' * min(z, e, r, o))

n=int(input())
c=input()

print("1 "*c.count("n")+"0 "* c.count("z"))


n=int(input())
s=input()
x=s.count('z')
y=(n-4*x)//3
print('1 '*y+'0 '*x)

input()
s = input()
n = 0
z = s.count('z')
for i in range(s.count('n')):
    print(1, end=' ')
for i in range(z):
    print(0, end=' ')

n = int(input())
s = input()
for i in range(s.count('n')):
    print(1,end = " ")
for i in range(s.count('z')):
    print(0, end =" ")

n = int(input())
A = input()

ones = A.count("n")
zeroes = A.count("z")

print(*[1 for i in range(ones)], *[0 for i in range(zeroes)])


n = int(input())
s = input()
zeros = s.count("z")
ones = s.count("n")
print("1 " * ones + "0 " * zeros)

n = int(input())
u = list(input())
r0 = 0
n1 = 0
for i in range(n):
    if u[i] == 'r':
        r0 += 1
    elif u[i] == 'n':
        n1 += 1
for i in range(n1):
    print(1, end = ' ')
for i in range(r0):
    print(0, end = ' ')


n=int(input())
a=list(input())
arr=[]
counter=a.count('n')
counter2=a.count('r')
for i in range(counter):
    arr.append(1)
for i in range(counter2):
    arr.append(0)
print(*arr)


L = int(input())

S = input()

n = S.count('n')
r = S.count('r')

ans = '1 ' * n + '0 ' * r

print(ans)

n=int(input())
s=str(input())
count1=s.count('n')
count2=s.count('r')
arr=[1]*count1
arr1=[0]*count2
arr=arr+arr1
print(*arr)


input()
X = input()
Z = X.count('z')
N = X.count('n')
print('1 ' * N + '0 ' * Z)


N = int(input())
S = input()

num_zeros = 0
num_ones = 0

for w in S:
    if w == 'z':
        num_zeros += 1
    if w == 'n':
        num_ones += 1

foo = ['1' for _ in range(num_ones)] + ['0' for _ in range(num_zeros)]
print(" ".join(foo))



n = int(input())
s = input()
z = s.count("z")
e = s.count("e")
r = s.count("r")
o = s.count("o")
n = s.count("n")
ones = min(o, n, e)
o -= ones
n -= ones
e -= ones
zeros = min(z, e, r, o)
res = []
res += [1] * ones
res += [0] * zeros
print(*res)

n = int(input())
s = input()
a = s.count("z")
b = (n - a * 4) // 3
print("1 " * b + "0 " * a)

import sys 
from collections import defaultdict
input = lambda : sys.stdin.readline().rstrip()

n = int(input())
s = input()
d = defaultdict(int)


one = s.count("n")
zero = s.count("z")

for i in range(one):
  print("1", end=" ")
for i in range(zero):
  print("0", end=" ")


#JMD
#Nagendra Jha-4096

 
import sys
import math

#import fractions
#import numpy
 
###File Operations###
fileoperation=0
if(fileoperation):
    orig_stdout = sys.stdout
    orig_stdin = sys.stdin
    inputfile = open('W:/Competitive Programming/input.txt', 'r')
    outputfile = open('W:/Competitive Programming/output.txt', 'w')
    sys.stdin = inputfile
    sys.stdout = outputfile

###Defines...###
mod=1000000007
 
###FUF's...###
def nospace(l):
    ans=''.join(str(i) for i in l)
    return ans
 
 
 
##### Main ####
t=1
for tt in range(t):
    n=int(input())
    s=str(input())
    a=s.count('n')
    b=s.count('z')
    for i in range(a):
        print(1,end=" ")
    for i in range(b):
        print(0,end=" ")
    print()
    
    
#####File Operations#####
if(fileoperation):
    sys.stdout = orig_stdout
    sys.stdin = orig_stdin
    inputfile.close()
    outputfile.close()

from math import*
t=int(input())
s=input()
n=s.count("n")
o=s.count("o")
e=s.count("e")
r=s.count("r")
z=s.count("z")
while o>0 and n>0 and e>0:
    print(1,end=' ')
    n-=1
    o-=1
    e-=1
while z>0:
    print(0,end=' ')
    z-=1

n = int(input())
s = input()
for i in range(s.count('n')):
    print(1, end=" ")
for i in range(s.count('z')):
    print(0, end=" ")