1 2 3 4 5 6 7 8 9 10 11 12
#!/usr/bin/python3 from sys import stdin, stdout def theFilter(line): return ( str(line).count("6") >= 8 ) while True: line = stdin.readline() if line == "": break if theFilter(line): stdout.write(line)