Python Variables


In Python variables are created the moment you assign a value to it:

Example

Variables in Python:

x = 5

y = "Hello, World!"

Python has no command for declaring a variable.

You will learn more about variables in the Python Variables chapter.


Comments

Python has commenting capability for the purpose of in-code documentation.

Comments start with a #, and Python will render the rest of the line as a comment:

Example

Comments in Python:

#This is a comment.

print("Hello, World!")

Jay Kakadiya

Jay Kakadiya Creator

I am a computer field, & i am Web developer.

Suggested Creators

Jay Kakadiya