程序師世界是廣大編程愛好者互助、分享、學習的平台,程序師世界有你更精彩!
首頁
編程語言
C語言|JAVA編程
Python編程
網頁編程
ASP編程|PHP編程
JSP編程
數據庫知識
MYSQL數據庫|SqlServer數據庫
Oracle數據庫|DB2數據庫
您现在的位置: 程式師世界 >> 編程語言 >  >> 更多編程語言 >> Python

1.python start - Introduction to variables and data types

編輯:Python

1. Data type classification , Describe some of their respective roles

Representing a numeric class :

1. The whole line int Represents an integer Function indicates age date
2. floating-point float Represents a decimal Function indicates height weight amount of money money
3. Boolean type :True and False , Used for conditional judgment
4. Plural type : I don't know what it's for ?

That represents the container class :

1. Sequence type :( You can find by index )
2. list list Multiple data Store the data , Can store any data type
3. Tuples tuple Multiple data Storing data , Can store any data type , You can't " Additions and deletions "
4. character string str A data Describe the nature of , It means name

2. Unordered type :( No index lookup )

 aggregate set Multiple data Store the data , You can put any data type Variable type
Dictionaries dict Multiple data Store the data :
key Only unchangeable types can be placed inside , Best string type
value You can put any data type in it

  1. 上一篇文章:
  2. 下一篇文章:
Copyright © 程式師世界 All Rights Reserved