Python from Beginner to Intermediate in 30 min
Python from Beginner to Intermediate in 30 min
What is Python?
Python:
Python is a programming language. It was created by Guido van Rossum. Guido van Rossum started implementing Python as a Hobby project in 1989 christhmas holidays.
Python is named after a BBC comedy show: Monty Pythons Flying Circus. The language is not named after this wonderfulsnake. To get Python, Go to www.python.org and download and install the latest versionof Python.
Python is free software. I am using Python3.5.0. The very latest version. Python is a simple and very powerful general purpose computer programming language.
If you want to learn programming or if you have never programmed before, then learning Python is a very good idea. Python is very easy to learn compared to other languages or Python programs arevery readable.
This is my Ubuntu GNU/Linux operating system desktop or my desktop. Toopen Python, open Terminal, the command line shell of linux.
Press CONTROL, SHIFT and PLUScouple of times to zoom in the window or you can go to the menu - View on top and clickon zoom in and type python3 and hit enter key. “” is called a “chevron” andwe can understand by seeing a cursor blinking after a “chevron” that we are in the Python Interpreter.
If you are on a Mac, you can open Python from Terminal. If you are on aWindows machine, I strongly recommend for using Python IDLE, the Integrated Development Environment of Python which is avaliable from www.python.org.
You can also use any TextEditor or any IDE of your choice. Hello World Program . This is the first program we write, when we are learning a new programming language.
This program is simply telling the computer to display the text “Hello World!” on thescreen. Type : print (Hello World) and hit Enter Key.
Hello World should be in quotes.We can see Hello World! printed on the screen. Welcome to the world of Python Programming or programming in general if you have never programmed before.
In the above program line,print() is a function and hello world is a string. Lets try the same print function with some other string. print Hot Coffee!) see!Hot Coffee! is printed. What if we want to store the Hello World programing the secondary memory or hard disk, so that we can use it again in the future.
In the terminal I am typing nano hello_world.py. Python Program File Extension is .py. I amusing a simple text editor called nano to make the hello world program. Simply type print (Hello World) save and exit from the nano editor.
To save press control and x and then press y for yes. ls command is for listing the directory. We can see the hello_world program in the directory or by GUI we can see the new file in the folder.
I am opening it in Gedit text editor so that you can see. I am going to execute the Python program we just wrote. Type Python space filename.py here hello_world.py Basic Arithmetic Operations Without Basic Arithmetic, Programming is nothing.
But believe me its not that difficult. Lets open Python Interpreter again, 15 + 23 and hit Enter key. see the answer printed back. This is arithmetic addition operation lets do subtraction 50 – 30the answer is 20 Multiplication 2 * 6 we use asterisk or star symbol for multiplication.
What if we are using **? 2 * 3 is 6.But 2 ** 3 is 8. This is called the exponentiation operation.or 10 ** 4 is 10000 or 10 raised to the power 4 is 10000.Division 15/6 is 2.5.
Modulo Division What is 15%6 ?it is 3 because that is the remainder after the division.Note that it is not slash but the percentage symbol.Lets do one more, 25 % 7 and the answer is 4.
Lets Review Python is a Programming Language. Creator is Guido van Rossum. Named after a BBC comedy show.
Hello World Program in Python is print (HelloWorld!) Python program file extention is .pyBasic Arithmetic Operations we just learned are Addition Subtraction Multiplication Division Exponentiation and Modulo Division .
Python:
Python is a programming language. It was created by Guido van Rossum. Guido van Rossum started implementing Python as a Hobby project in 1989 christhmas holidays.
Python is named after a BBC comedy show: Monty Pythons Flying Circus. The language is not named after this wonderfulsnake. To get Python, Go to www.python.org and download and install the latest versionof Python.
Python is free software. I am using Python3.5.0. The very latest version. Python is a simple and very powerful general purpose computer programming language.
If you want to learn programming or if you have never programmed before, then learning Python is a very good idea. Python is very easy to learn compared to other languages or Python programs arevery readable.
This is my Ubuntu GNU/Linux operating system desktop or my desktop. Toopen Python, open Terminal, the command line shell of linux.
Press CONTROL, SHIFT and PLUScouple of times to zoom in the window or you can go to the menu - View on top and clickon zoom in and type python3 and hit enter key. “” is called a “chevron” andwe can understand by seeing a cursor blinking after a “chevron” that we are in the Python Interpreter.
If you are on a Mac, you can open Python from Terminal. If you are on aWindows machine, I strongly recommend for using Python IDLE, the Integrated Development Environment of Python which is avaliable from www.python.org.
You can also use any TextEditor or any IDE of your choice. Hello World Program . This is the first program we write, when we are learning a new programming language.
This program is simply telling the computer to display the text “Hello World!” on thescreen. Type : print (Hello World) and hit Enter Key.
Hello World should be in quotes.We can see Hello World! printed on the screen. Welcome to the world of Python Programming or programming in general if you have never programmed before.
In the above program line,print() is a function and hello world is a string. Lets try the same print function with some other string. print Hot Coffee!) see!Hot Coffee! is printed. What if we want to store the Hello World programing the secondary memory or hard disk, so that we can use it again in the future.
In the terminal I am typing nano hello_world.py. Python Program File Extension is .py. I amusing a simple text editor called nano to make the hello world program. Simply type print (Hello World) save and exit from the nano editor.
To save press control and x and then press y for yes. ls command is for listing the directory. We can see the hello_world program in the directory or by GUI we can see the new file in the folder.
I am opening it in Gedit text editor so that you can see. I am going to execute the Python program we just wrote. Type Python space filename.py here hello_world.py Basic Arithmetic Operations Without Basic Arithmetic, Programming is nothing.
But believe me its not that difficult. Lets open Python Interpreter again, 15 + 23 and hit Enter key. see the answer printed back. This is arithmetic addition operation lets do subtraction 50 – 30the answer is 20 Multiplication 2 * 6 we use asterisk or star symbol for multiplication.
What if we are using **? 2 * 3 is 6.But 2 ** 3 is 8. This is called the exponentiation operation.or 10 ** 4 is 10000 or 10 raised to the power 4 is 10000.Division 15/6 is 2.5.
Modulo Division What is 15%6 ?it is 3 because that is the remainder after the division.Note that it is not slash but the percentage symbol.Lets do one more, 25 % 7 and the answer is 4.
Lets Review Python is a Programming Language. Creator is Guido van Rossum. Named after a BBC comedy show.
Hello World Program in Python is print (HelloWorld!) Python program file extention is .pyBasic Arithmetic Operations we just learned are Addition Subtraction Multiplication Division Exponentiation and Modulo Division .
Validity 1 10 10 days
With Certificate
With Certificate
0 Comments
Please do not enter any spam link in the comment box.