variables and data types in python.
pdf link :- https://drive.google.com/file/d/11Ec_QW0rZw7JoZUYfiRubXS2MQLAPEBv/view?usp=share_link
intro to python video link :- https://youtu.be/8GyPastgLrY
In Python, a variable is a named location in memory where a value can be stored and retrieved. The value stored in a variable can be of different data types, such as:
String: a sequence of characters, represented by either single or double quotes, e.g. "hello" or 'world'.
Integer: a whole number, e.g. 42.
Float: a decimal number, e.g. 3.14.
Boolean: a binary value that can be either True or False.
List: an ordered collection of values, e.g. [1, 2, 3].
Tuple: an immutable ordered collection of values, e.g. (1, 2, 3).
Dictionary: an unordered collection of key-value pairs, e.g. {"key1": "value1", "key2": "value2"}.
Set: an unordered collection of unique values, e.g. {1, 2, 3}.
In Python, you can use the type() function to determine the data type of a value or a variable.
#variables #data-types #python #string #integer #float #boolean #list #tuple #dictionary #settings #python #variables #datatypes #string #int #float #bool #list #tuple #dictionary #set #programming #coding #tutorial #learnpython