“Типы данных Python” Ответ

переменные и типы данных в Python

~Variables & Data types: 
 It represents the kind of value that tells what operations can be 
 performed on a particular data. Since everything is an object in 
 Python programming, data types are actually classes and variables 
 are instance (object) of these classes.

#Assigning Single Values 
  
character_name = "John" 
print(character_name)
#Variables-consits of at least some sort of info inside them
print(type(character_name))

#Data types-tells us if the output is a string or integer or another 
#form of data type such as the following:

#Floating Point(decimal)
#Character
#String
#Boolean
#Enumerated type
#Array
#Date
#Integer

character_age = "75" #This will be a string as I'm using ""
print(character_age)
print(type(character_age))

is_male = True #Boolean Value
print("Hi my name is " + character_name + ", I like to play basketball")
print("I am " + character_age + " years old, but, still enjoy playing this sport.")

charater_name1 = "Mike"
character_age1 = "75"

is_female = False #Boolean Value
print("His friend " + charater_name1 + " also enjoys playing basketball")
print("YET! Again he's also " + character_age1 + ".")

Boolean Value
The boolean gives us two paths either true or false, if the 
password was wrong the computer will return false, however 
if it is right then the computer will generate true
Abstract

Что такое типы данных в Python

In programming, data type is an important concept.

Variables can store data of different types, and different types can do different things.
Text Type:	str
Numeric Types:	int, float, complex
Sequence Types:	list, tuple, range
Mapping Type:	dict
Set Types:	set, frozenset
Boolean Type:	bool
Binary Types:	bytes, bytearray, memoryview
Programmer of empires

Типы данных Python

x = 5
print(type(x))
Busy Buffalo

Ответы похожие на “Типы данных Python”

Смотреть популярные ответы по языку

Смотреть другие языки программирования