Advertisement
Guest User

Untitled

a guest
Sep 26th, 2017
53
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.23 KB | None | 0 0
  1. >>> cities = open('c:\cities.raw')
  2. >>> out = open('cities2.raw', 'wb')
  3. >>> i = 0
  4. >>> 21162 / 4
  5. 5290
  6. >>> chunk = cities.read(5290)
  7. >>> while chunk:
  8. if i % 4 is not 2:
  9. out.write(chunk)
  10. i += 1
  11. chunk = cities.read(5290)
  12.  
  13.  
  14. >>>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement