In C, Java or Some Other Programming Languages, A Variable Is An Identifier or A Name, Connected To Memory Location
In C, Java or Some Other Programming Languages, A Variable Is An Identifier or A Name, Connected To Memory Location
y=a
y
30
12678
Variable
In Python, a variable is considered as tag that is tied to some value. Python
considers value as objects.
a = 10 b = 10 a = 20
a b a
10 10 20
12114 12115 12117
y=a
y
20
12678
Variable
In Python, a variable is considered as tag that is tied to some value. Python
considers value as objects.
a = 10 a = 20
a a
10 20
12114 12115
• Except underscore ( _ ) no other special symbol are allowed in the middle of the variable
declaration
• No Reserved keyword
Examples
Do Don’t
• A • and
• a • 15name
• name • $city
• name15 • Full$Name
• _city • Full Name
• Full_name
• FullName