دوره Python Data Structures ، فصل 3 : Chapter Seven- Files

درباره‌ی این فصل:

Up to now, we have been working with data that is read from the user or data in constants. But real programs process much larger amounts of data by reading and writing files on the secondary storage on your computer. In this chapter we start to write our first programs that read, scan, and process real data.

این دوره شامل 5 فصل زیر است:

So, everything we've done up until now has been sort of just if a tree falls in the forest, if a variable gets set in a computer and no one reads it, did it really happen? So we actually haven't done anything that touches the real world, I guess we did help people get out of lost elevators, but other than that, we haven't done much interesting at all. It shows you the \n, but if you run it on a print statement, it actually interprets it and treats that as a nonprinting character that basically moves to the beginning of the next line.

So again, the for loop is going to run this code multiple times where the iteration variable, cheese in this case, is going to take on the successive lines. So that just says treat a file handle as a sequence of lines, and allow us to iterate through it automatically using the for loop. The text from the file did this and then the print statement did one more and so then we ended up with new blank lines.

I saved this so it's an empty file, and Python's perfectly happy running absolutely nothing because I guess you've made no mistakes. And so you see that by my action here in the browser, I have saved the file into the exact same folder that I've got the code for 7_1. There is a non-printing character at the end of every line called a newline which is the way in files we store the fact that it goes back to the beginning.

Here we are in Barcelona at office hours, and I'd like to introduce some of the students in Internet history technology for the very first time it was taught. Hi this is Marta Martinez, it is lovely to take courses at Coursera and I hope you take it too. Hi, My name is Daniel, I loved it so, enjoy your courses.

I recently met with Bell at the Computer History Museum in front of a fully restored and operational PDP-1. Yeah, well, the interesting thing about that as being the first video game was, Harlan Anderson, one of the founders I think, had discovered at the end of the year that he could give a computer away and get total tax deduction for that and I think it, I don't know that, whether that was the thing that made us profitable that year or not. Steve Russel and Peter Sampson, Allen Kotok came in and took a lot, took a lot of the software ideas that had been developed for PDP-1, and transformed them onto the that was on the TX-0, put them on PDP-1, and that, things like all the first editor, which we called Expensive Typewriter, debugging, interactive debugging, all the light pen kinds of interactions, connections, and then the, I think the most famous one that is still in a sense in use is, was Spacewar.

مشارکت کنندگان در این صفحه

تا کنون فردی در بازسازی این صفحه مشارکت نداشته است.

🖊 شما نیز می‌توانید برای مشارکت در ترجمه‌ی این صفحه یا اصلاح متن انگلیسی، به این لینک مراجعه بفرمایید.