Last week I learnt the basics of Python. This week I learnt some things you can do with it.
I did a Pong in Python tutorial and it was fun. It was for beginners to coding and I did think that some bits of code were quite repetitive and it could be improved, but I don't know how. And the point of this isn't to know how, it's just to know a bit about the language.
Also, setting the ball speed was a bit interesting. Sometimes it would be so fast it would fly off before I could even think about moving the paddle and sometimes it was so slow I got bored waiting for it to reach the paddle. And sometimes it would start fast and then slow down. My guess is that it's very affected by whatever else is going on on my computer. The trick was mostly to run it a few times until it was the right speed, and then play.
I just had to stop myself from wanting to put semi-colons at the end of lines, and put 'const' before all the variable declarations.
For this I did a REST API tutorial. This started off with a talk about APIs, which was a good reminder. Then we used one, which was fine. And then made one, using Flask and an SQL database and I pretty much had no idea what was going on. It was too much new stuff in one go.
This was a short tutorial about using Beautiful Soup. Because he had the code already written, just commented out, I was often ahead of him, with understanding what was going on. It was just an introduction, but I can imagine you'd want to put what you'd got in a database.
The point of this was to learn a little about a language I'm curious about and I have achieved that.
Latest comments (0)