Chapter 3 - Data Types
Chapter 3 - Data Types
Integer
Number Complex
Boolean
Dictionary
Set
String
Tuple
NOTE :- The fundamental data type in python are :- Int, float, complex, str, bool
Tuple :- Tuple is exactly same as list but tuple is not mutable (i.e. immutable) like list
Basically tuple is read only version of list
E.g. – (10, 20, ‘python’, ‘30’, True)
Bool :- used to represent Boolean values, only two values are allowed True, False
Range :- range data type represent a sequence of numbers. The elements present in
a range data type are not modifiable i.e. immutable. We can access values in range
data type using index.
range (10,20,2) -> 2 represent increment value, we can put any value in place