Python-features
Python- Facts
The above images are from the textbook and discussion today is based on them.
Feel free to download and save for reference
Feel free to download and save for reference
By the end of this session, you will be able to understand the important features of Python Programing Language.
____________________________________________________________
Before we take up the key features of Python, lets first see why should we study Python!
(URL of the above video, incase you can't view: https://youtu.be/Y8Tko2YC5hA)
So, without much ado, lets embark on the journey to explore PYTHON...
---------------------------------------------------------------------------------------------
Let us take a review of the key features of Python discussed in the last class:
- Simple-
- Written in simple English statements.
- Therefore, it is easy to understand the syntax( way of writing) and develop programs.
2. Easy to learn-
- uses very few keywords (set of special words which have a specific meaning).
- structure of program is very simple and easy to create.
At this point, it is imperative to highlight the following terms:
1. Source code is a program written in a programming language (or in assembly language).
2. Machine code is the directly executable binary representation of a computer program.The CPU can directly execute this code.
3. Byte code is artificial machine code for a virtual machine or VM, such as the Java VM or the Python VM( PVM). It is intermediate code between source code and machine code that is executed by a so called virtual machine. Source code is code written according to a programming language specification, could be compiled or interpreted, and can be executed.
4. Object code is the result of compilation of a module or program written in a programming language, stored for later use.
__________________________________________________
Let us move ahead with the key features of Python, which is our discussion for today.
(All of you are expected to note the following in your registers:)
Let us move ahead with the key features of Python, which is our discussion for today.
(All of you are expected to note the following in your registers:)
3. Platform Independent and portable-
- Can run on any platform (Operating System/hardware)
- Code created on Windows machine can run it on Mac or Linux ( other common Operating systems).
- Bytocode is generated by Python compiler
- Bytecode represents a fixed set of instructions that run on all Operating Systems and hardware using the PVM (Python Virtual Machine).
4. Open Source-
- Python is available for free
- Can be downloaded from www.python.org website.
- Its source can be read and modified by the user ,that is how it gets the name "Open Source" (code).
5. Dynamically typed-
- In Python, there is no need to declare anything.
- An assignment statement ( eg a=b+c), binds the name of the object, which can be of any type.
- It can be changed to a different type ,anytime.
- There is no need to define the type(int or float) of the variable.
6. Huge Library-
- It has large inbuilt library (collection)
- It contains pre-built and portable functionality, known as standard library
- It makes the program building process easy and fast, as pre-built modules are available which can be easily included by a programer in his program.
7. Procedure and Object Oriented-
- Is Object oriented.- Object-oriented Programming(OOP) is a programming language that uses classes and objects to create models based on the real world environment. In OOPs it makes it easy to maintain and modify existing code as new objects are created inheriting characteristics from existing ones.
- Is Procedure oriented- On other hand Procedural Oriented Programming is a programming language that follows a step-by-step approach to break down a task into a collection of variables and routines (or subroutines) through a sequence of instructions. Each step is carried out in order in a systematic manner so that a computer can understand what to do.
- Python file extension is .py
- Bytecode file extension is .pyc
- Python is referred to as "interpreted language"-
- compiler converts the .py bytecode for the PVM
- An interpreter executes this bytecode on the Virtual Machine.
EXERCISE
Q1 What do you mean by "Platform Independent"?
Q2. How is Python portable?
Q3. Why is Python called "Open Source"? Name a few other Open source software that you are aware of.
Q4. How is Python "Dynamic"?
Q5. What is standard library? How does it help?
Q6. Why is Python referred to as interpreted language? Support the explanation with a well labelled diagram.
Q7. Differentiate between ".py" and ".pyc".
Good Morning Ma'am
ReplyDeleteKavyansh Bagotra 9D
Good morning ma'am! I am Arjav Jain from 9D
ReplyDeletegood morning mam i am aryan mahehswari
ReplyDeleteGood morning ma'am I am Waqar of class 9-D
ReplyDeleteWhat is you roll no?
DeleteGood Morning Ma'am
ReplyDeleteThis is Joshua Walter of Class 9-D.
Good Morning ma'am I am soumil Arora
ReplyDeleteGood morning boys. In the coming few sessions we may be using google meet based sessions where I will send you a meeting ID on the blog.
ReplyDeleteYou need to install/ connect to Google meet application. Kindly make the necessary arrangements.
Good morning maam i am samaksh goswami of class 9D
ReplyDeleteThis is Arnav Trivedy
ReplyDeleteGood morning ma'am.samarth raj 9D
ReplyDeleteGood morning Ma'am I am Kenn of9d
ReplyDeleteGood morning Ma’am.
ReplyDeleteMy name is Ryan Rahuel Valentine from Class 9D.
Good morning ma'am this is Vincent Zacharias
ReplyDeleteGood morning mam I am Kritik Kuraria
ReplyDeleteGood morning maam I am Satwik Pruthi of class 9D
ReplyDeleteGood morning ma'am.
ReplyDeleteMy name is Ojas Khanna
Good Moring Maam this is Aryan Joseph
ReplyDeleteGood Morning Ma'am .My name is Advait Mohanty of class 9D.
ReplyDeleteGood morning ma'am.
ReplyDeleteSarhan Akhtar 9D.
Good morning ma'am I am vansh bharti of class 9D
ReplyDeleteGood Morning ma'am
ReplyDeleteAaron john
Ma'am will python work on mac
ReplyDeleteYes. Pls read the features. It can work on any platform
DeleteOk ma'am
DeleteGood Morning Mam. I am
ReplyDeleteAbhishek Dial 9 D
All boys to note the following steps and be ready for Google meet sessions--
ReplyDeleteSteps to join the Google Meet:
1. In a web browser, enter https://meet.google.com.
2. Click Join meeting.
• Enter a meeting code .
• The meeting code is the string of letters at the end of the meeting link. You don't have to enter the hyphens.
3. Click Continue and then Join now.
Good Morning Mam I am Derick Joseph of 9D
ReplyDeleteYou are very late Derick
DeleteIs there any doubt or confusion? Pls share
ReplyDeleteGood Morning ma'am
ReplyDeleteI am Mohnish Kansal 9D
Mohnish the class is about to end and you are joining now. I am sorry. In future, i wont give attendance
DeleteGood Morning Ma'am I am Karan Kapoor of class 9-D
ReplyDeleteKaran the class is about to end and you are joining now. I am sorry. In future, i wont give attendance
ReplyDeleteGood Morning ma'am.I am Gracious Benny of class9-D
ReplyDeleteGood morning mam I am Ibrahim khan of 9D
ReplyDelete