| 125 | |
| 126 | print("Example 10") |
| 127 | class ReadVisits: |
| 128 | def __init__(self, data_path): |
| 129 | self.data_path = data_path |
| 130 | |
| 131 | def __iter__(self): |
| 132 | with open(self.data_path) as f: |
| 133 | for line in f: |
| 134 | yield int(line) |
| 135 | |
| 136 | |
| 137 | print("Example 11") |