Last active
December 1, 2020 13:34
-
-
Save gnn/53f7fe609059466ecde020f4d62da0dd to your computer and use it in GitHub Desktop.
Using zipped files with Python
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import zipfile | |
with zipfile.ZipFile(PATH_TO_ZIPFILE) as zf: | |
for filename in zf.namelist(): | |
zf.extract(filename) | |
# Do stuff with `filename`. | |
os.remove(filename) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment