i=0 for c in open('/dev/fd/0').read(): if'Y'==c:print i i+=1