Explore the World's Best Ideas
Join today and uncover 100+ curated journeys from 50+ topics. Unlock access to our mobile app with extensive features.
Python is low-level coding language, meaning that it is meant for oneās self to understand. Python is easy to start learn for beginners and is used for a lots things. Google, YouTube, and even Netflix use Python along with other companies and organizations.
1
3 reads
To output text the console of terminal screen in Python 3 use the command print(āyour textā). You can replace the your text with anything like print(āHow are youā)
1
2 reads
To allow a user to input a variable, number, or some text in Python 3 you will use the input function. input(āyour textā) this will pause the program and allow the user to input something. To save the users input as a variable for later use use this input function. Your_variable = input(āyour textā) this will allow the program to save the users input as a variable which in this case the users input is saved as Your_variable and this can also be replaced with custom variable name
1
2 reads
Variable in Python 3 are important. Almost any program you write or use will probably use variables. To make a variable, type this in your code when needed. Your_variable = 4 you can this variable from a integer to a string using āyour text ā after the equals sign of your True of False after the equals sign to make a Boolean variable. To output a variable to the screen use the print function like this. print(score) in Order to do this you need to state your variable before the print function. To add a variable in the middle of a print function use this function. print(āyour score isā + score)
1
0 reads
if else statements are also very important. To use a if else statement use this function if score == 4:
print(āyour score is goodā)
else:
print(ā your score is excellentā)
Anything after the else or if statement on the next should be indented to be apart of the statement(s). Your statement can equal a number, text, of a Boolean.
To replace the double equals sign
== Exactly equal
!= Not equal
> Greater than
< Less than
>= Greater than equal to
1
1 read
To end the program properly at certain point use the quit command which is
quit()
this will properly end the program
1
2 reads
In the picture above it displays a simple program I made from the tutorial you have just read.
1
1 read
you have now made it to the end of the tutorial. I hope you have learn some good information for this stash. You should be able to now create a small program in Python 3 like me. Comment and like! Follow for more coding tips.
1
0 reads
IDEAS CURATED BY
CURATOR'S NOTE
Remember even I cover Python 3.10 all version of Python are case-sensitive so type the functions word for word. If you donāt understand something in this tutorial search it up on the web. Comment and like. Follow for more coding tips and tricks!
ā
Similar ideas
1 idea
21 ideas
21 Mind Traps: A Guide to your most common Thinking errors (Part II)
Escaping Ordinary (B.C Marx)
Read & Learn
20x Faster
without
deepstash
with
deepstash
with
deepstash
Personalized microlearning
ā
100+ Learning Journeys
ā
Access to 200,000+ ideas
ā
Access to the mobile app
ā
Unlimited idea saving
ā
ā
Unlimited history
ā
ā
Unlimited listening to ideas
ā
ā
Downloading & offline access
ā
ā
Supercharge your mind with one idea per day
Enter your email and spend 1 minute every day to learn something new.
I agree to receive email updates