0% found this document useful (0 votes)
2 views1 page

Python Notes

The document outlines a series of Python programming instructions for handling user input, including name manipulation and data type conversions. It provides methods for capitalizing names, splitting strings, and creating variables of different types such as integers, floats, and booleans. Additionally, it includes commands for running Python code and managing files in the terminal.

Uploaded by

quabenahayes2019
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as RTF, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views1 page

Python Notes

The document outlines a series of Python programming instructions for handling user input, including name manipulation and data type conversions. It provides methods for capitalizing names, splitting strings, and creating variables of different types such as integers, floats, and booleans. Additionally, it includes commands for running Python code and managing files in the terminal.

Uploaded by

quabenahayes2019
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as RTF, PDF, TXT or read online on Scribd
You are on page 1/ 1

1. Ask user for the name: Name = input(“What is your name?

”)
2. Remove whitespace for string: name = name.strip()
3. Capitalize the user's first name: name = name.capitalize()
4. Capitalize the first letter name: name = name.title()
5. Alternative way of writing +name: ,name
6. Summary alternatively: name = input(“Whats your name?”).strip().title()
7. Split users name into first and then last name: first, last = name.split(“ “)
8. String = str (names)
9. Integer = int (numbers -+)
10. Float = float (decimals)
11. Boolien = bool (True or False)
12. >>> = python in interactive mode
13. Run code = type python, then saved file name.py + enter
14. Create a new file in terminal: Code + file name .py
15. Exit from interactive mode: Exit()
16. When inputting a string function that is calculable type: int(print(“”))
17.

You might also like