Python Jumpstart by Building 10 Apps Transcripts
Chapter: App 4: Journal app and file I/O
Lecture: Intro to the journal app
0:00 It's time for app number 4 and this time we are going to build a daily journal, or a diary.
0:05 So let's look at what we are going to build, what it's going to look like. Here is the output we are going to expect from our app
0:11 you can see as always there's a header notice there is a few diagnostics messages there saying we are loading our data from a file
0:18 and at the end you can see saving to a file. So one of the primary focuses of this app is on File I/O
0:25 and you can see the main part of the app gives you this menu and says what do you want to do list your journal entries, add a new one or exit.
0:31 And if we hit "L" you can see we are listing out a few items if we add one it gets appended
0:36 and we persist this across running instances of the app, in our file. While that may sound pretty straightforward
0:43 we are actually going to cover a ton of topics. We are going to break our application into multiple Python files and use them between each other.
0:50 We are going to talk about this thing called live templates in PyCharm, as I already said we are going to focus on File I/O.
0:56 We are going to work with the most common type of loop in Python called the for-in loop.
1:00 We are going to talk about documenting our code with these things called docstrings. We are going along with File I/O and talk about how we manage
1:07 file paths and combine file paths segments in a platform independent way. We are also going to talk about how we define methods
1:15 and how we can structure our code so that we can sort of define them in what order makes sense and then use them in any order we'd like.
1:22 And last but not least, we are going to talk about complex conditional expressions we've been working with very basic conditionals before,
1:30 but we'll get a little more involved in this one as well.