CLASS XI COMPUTER SCIENCE
CHAPTER 5 – GETTING STARTED WITH PYTHON
THEORETICAL PORTION
1. Characteristics of Python
• Cross-Platform Language: Works on various operating system
• Open Source: Freely available and distributable
• High level language
• Interpreted language
• Object-oriented language
2. Difference between INTERPRETER and COMPILER
• COMPILER :
Translates entire program at once
FAST
Generates object code and list of errors
Eg : C and C++ are compiled languages.
• INTERPRETER :
Translates line by line
Slower
Prompts the programmer to correct the encountered errors
Eg : Python is a compiled language.
3. Disadvantages of Python
• Slower as it is interpreted
• Consumes high memory
• Limited database access
• Errors show up only at runtime
4. Python IDLE
• Integrated Development and Learning Environment
• It is a program that allows the user to edit, run, browse and debug a
python program from a single place.
5. Two Modes
• Script mode : (or Python Editor) Python instructions are stored with .py
extension. Script mode is useful for creating programs and then run the
programs later and get complete output.
• Interactive mode : (or Python Shell) We type one command at a time,
the command executes and output is shown. Interactive mode is suitable
for testing code.
6. Important Points
• Spyder IDE: It is an integrated development environment with editing,
testing and debugging features. It is preloaded with Anaconda
distribution.
• Jupyter Notebook: It is a web based interactive computing environment.
• Popular Python distributions are CPython (default), Anaconda
distribution etc.
• Popular Python IDEs are Python IDLE, Spyder IDE, Jupyter Notebook,
Pycharm IDE etc.