New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PCC54 yashaslokesh #410

merged 1 commit into from Nov 9, 2018


None yet
2 participants

yashaslokesh commented Oct 31, 2018

ATTENTION: before clicking "Create Pull Request" please submit some meta data, thanks!

Difficulty level (1-10): [4]
Estimated time spent (hours): [3]
Completed (yes/no): [yes]
I stretched my coding skills (if yes what did you learn?): [Gained more experience representing datetime objects as strings in the format I want them, used error handling to make my code more concise, and found the useful string method splitlines() which gives a list of all strings separated by newlines. I can easily insert an element into the list and then reform the list into file contents. This is much easier than parsing through a string of all the file contents to find a certain location.]
Other feedback (what can we improve?): []


This comment has been minimized.


pybites commented Nov 9, 2018

Great learning documentation, thanks. Nice error handling. I like splitlines but it is not lazy, is it? Only recently found out that the file object is already a lazy generator of lines - see

@pybites pybites merged commit 51b8e49 into pybites:community Nov 9, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment