Python

 

Python is an interpreted high-level general-purpose programming language. Python's design philosophy emphasizes code readability with its notable use of significant indentation. Its language constructs as well as its object-oriented approach aim to help programmers write clear, logical code for small and large-scale projects. Python is dynamically-typed and garbage-collected. It supports multiple programming paradigms, including structured (particularly, procedural), object-oriented and functional programming. Python is often described as a "batteries included" language due to its comprehensive standard library.


Basics Of Python

1) Displaying Text on The Screen

To display any text on the screen we use Print command.

A) Code to display the text on the screen.

Code = Print("Hello, My name is Yash Vardhan")

Output = Hello, My name is Yash Vardhan

B) Code to display the answer of any calculation of mathematics.

Code = print(2+3)

output = 5

2) Storing values in variables

We can store values in variables in python. It is useful when you are making a project and you have to do mathematics calculations. 

code = a = any value 

            b = any value

            print(a+b)

            print(a-b)

            print(a*b)

            print(a/b)

It is not necessary that you name the variable as a and b only, you can give any name to the variable and don't write "a = any value" I have written this to explain that what should be written after the variable. For more understanding watch this video.


If it helps you to understand then please subscribe my channel and like my videos. 

Thank You 

Yash Vardhan





 


Comments