- Download the required python 2.7.13 software from the following website http://www.python.org/downloads
- Click on the downloaded installer file.
- Click on the run.
- Click on the next.
- Click on the next.
- Click on the next.
- Click on yes.
- Click on finish.
Development of Python applications (or) programs
We can develop python application/programs in 2 modes. They are -
1. Interactive mode - It is a command line shell. In command line shell if we write any python statement immediately that statement will execute and gives the result. Interactive mode is used to test the features of the python(what python can do).
Note : Interactive mode is not used for development of the business applications.
Open command prompt -
C:\> cd Python27
C:\Python27> python
>>> 10+20
30
>>> 10/2
5
>>> i=1000
>>> j=2000
>>> print i+j
3000
2. Batch mode - In batch mode we write group of python statements in any one of the editors (or) IDE's. Different editors are - Notepad, Notepad++, EditPlus, Gedit etc. Different IDE's are - Pycharm, Eric, Eclipse, Netbeans etc.
After writing the group of python statements in anyone of the editor / IDE we save the file with extension ".py" or ".pyw"
After developing the .py or .pyw files we submit those files to the python interpreter directly.
Batch mode is used for development of business applications.
Write the following code
i=1000
j=200
print i+j
print i-j
Save the above file with demo.py in C-drive Python27 folder or directory.
Open the command prompt C:\Python27>python demo.py
1200
800
Note : Whenever we install the python software in windows operating system along with the python software 'IDLE' or 'Python 'GUI' editors will be installed.
In IDLE editor we can develop the python programs in interactive and batch mode.
After developing the python application in IDLE editor directly we can run that python application by using shortcut key(F5).
Within the IDLE editor we can perform the debugging operation of the python applications
Any organization contains 2 parts - Data and Operations.
Data of any organization we can represent by using any programming language.
To represent the data of organizations programming language are providing datatypes and variables.
Every programming language supports datatypes and variables but the datatypes and variables of one language are not going to be same with another programming language.
Operations of the organizations we can represent by using any programming language.
To represent the operations of the organizations every programming language is providing functions or methods or both.
No comments:
Post a Comment