In this tutorial I want to say to you about a basic python program. So we are going to write it as a very simple python program. We are going to look at how we can go ahead and write up program we are going to talk about. How our program are getting executed by python. And we are going to draw out a little shape onto the screen. This is going to be pretty cool. I am excited to talk you guys about just the very basics of python and really just sort of give you an introduction.
So we can actually print something out onto the screen and python using something called a print statement. So I can just type out
print(" /|") print(" / |") print(" / |") print(" / |") print(" /____|")
When we use this print statement were basically telling python like Just print something out onto the console. There is a lot of situations where we are gonna see what is going on in our code. We can use that print statement and print things out to the console. And we can basically like have a little window into what our program doing. In out case, we are just going to be printing out this triangle onto the console. I can really draw any shape I want it as long as i was ale to specify inside of those print statements.
Python is actually going to execute the line of code that we write in order. So the order in which I write the instructions matter a lot.
So this is basically how your Python programs are going to go. We can essentially just define these little instructions for the computer, and the computer will execute them in order.
Comments
Post a Comment