a.py (324B) [raw]
1 #!/usr/bin/env python3 2 import sys 3 4 count = 0 5 for l in sys.stdin: 6 seen = False 7 for sig in l.strip().split(" "): 8 if sig == "|": 9 seen = True 10 elif not seen: 11 continue 12 if len(sig) == 2 or len(sig) == 7 or len(sig) == 4 or len(sig) == 3: 13 count += 1 14 15 print(count)