Python tutorial 2
Python Basics • Always use .py as extention First Command of Python in VS code # Make a python file # Write print, bracket and double comma in it then text you want to write. #e.g [print ("Hello")] ([] long bracket not to be written.) # Save the file #Press Run Button on top right area of window # File will run in prompt Commenting out in Python # To comment out in python write '# ' as first character of line # Commenting out means that when your command runs than python interpreter will skip the line. It is usually used as a remark for the code Assigning Variables in python # Assigning variable in python is same as letting a variable in maths. # To assign a variable write a variable (A variable can be a letter abc...) write equal to a 'number' or a 'word' or another variable # E.g [a = 2 ][b = 'python'][ a =b][ c = 10.9] # Write print, bracket, variable in it # E.g print(a) {dont write print("a")} Arthrmatic Opera