Guibs’ Python Learning_Variables# Naming and using variables # Variable names can only contain letters, numbers and underscores. [Cannot start with a number] [001_send message x][send_message_001 ✔]️ # Variable names cannot contain spaces, and underscores can be used to separate words [send message x][send_message ✔]️ # Python keywords and function names cannot be used as variable names # Variable names should be short and descriptive. For example, name: [n x][name ✔]️ # Note the use of l and O, some fonts will be combined with 1 and&
1. Guibs’ Python learning_variable
Introduction: Naming and using variables # Variable names can only contain letters, numbers and underscores. [Cannot start with a number] [001_send message x][send_message_001 ✔] ️ # Variable names cannot contain spaces, and underscores can be used to separate words [send message x][send_message ✔]️ # Python keywords and function names cannot be used as variable names
2 . Guibs Python Learning_String
##Introduction: # String # Python, Everything enclosed in quotation marks is a string. The quotation marks can be single quotation marks or double quotation marks "This is a string"
3. Guibs' Python Learning_Numbers
Introduction: # Number # Integer # In Python, integers can be added (+) or subtracted (-) Multiply (*) Divide (/) Modular division (%) [Find remainder] Power (**)
4. Guibs’ Python learning_Python Zen
Introduction: The Zen of Python, by Tim Peters, Python Learning by Guibs_Zen of Python
5. Guibs’ Python learning_list
Introduction:
6. Python learning with Guibs_Tuple
Introduction: # Tuple# Tuple is equivalent to an immutable list, using parentheses ()
Introduction: # if # if controls whether the code block belongs to if through indentation # if conditional_test : # do something
8. Guibs’ Python Learning_Dictionary
##Introduction: Dictionary# A dictionary in Python is a series of key-value pairs. # Use: to separate keys and values, and use to separate key-value pairs.
9.
Python Learning with Guibs_While&Input
Introduction: Python Learning with Guibs_ The strength code of While&Input, if you need it, you can refer to it
10. Python Learning with Guibs_ Function
Introduction: This chapter Describes the sample code of Guibs' Python learning_ function. If you need it, you can refer to it
The above is the detailed content of Detailed introduction to Guibs. For more information, please follow other related articles on the PHP Chinese website!