lecture1
lecture1
Dynamic
HLL
Introduction to Python
Versatile
Why do we need programming?
5 x 10 ?
7315 x 2 ? The Prediction/Data Analysis:
Q.1. What will be the temperature on 11th Sep?
7615 x 987 ?
Q.2. Will it rain
Q.3. Can Python be on 11th Sep?
used as Calculator?
Why – Guido
was watching
a show by name
Monty Python’s
Circus when
working on this
language and
thought why not
name it as Python.
Extensible
Platform
and
Independent
Embeddable
Portable and
Benefits of Python Robust
Interpreted
(bytecode-
compiled)
137000 libraries
Python has a vast and continuously growing ecosystem of libraries. The total
numbers of Python are more than 137000 libraries. All these libraries are used
in machine learning, data science, data manipulation and visualization, and more.
Which
game is
this?
May be downloaded
directly and stored
under system
Downloads folder
Function
module is simply a file containing Python code. This code can include functions, Will be
classes, variables, and runnable code. When you save your Python code in a .py discussed
file, it becomes a module that can be imported and used in other Python programs. in detailed
in Lec 10
Example: Consider you have a file named This file example.py is a module. You can import it into Module and 11
example.py with the following content: another Python script or module and use its functions:
Package
Library
Package is a collection of modules. That means, the package is a directory that
contains collection of modules and a collection of packages or sub-packages
Framework
Library is collection of packages and frameworks are collection of libraries
Slide 033
Do we other IDE’s to install modules?
IDE stands for Integrated Development Environment
>Pycharm
>IDLE
>Jupyter Notebook
>VS Code
An IDE is like a well-equipped kitchen for a chef, providing all the necessary tools and facilities to efficiently create, test, and manage
software projects. Just as a chef uses various kitchen tools to prepare a meal, a programmer uses an IDE to develop software.
While you can write and run Python code using a text editor and the command prompt, an IDE offers a comprehensive set of tools and
features that can significantly improve your development workflow. From code editing and debugging to project management and
collaboration, an IDE provides a more efficient and productive environment for software development.
For windows users: If you see single > in your terminal this means For MacOs users: If you see single % in your terminal this means you
you are outside the python environment and you can install the packages are outside the python environment and you can install the packages
For windows users: If you see this prompt >>> in your terminal this For MacOs users: If you see this prompt >>> in your terminal this
means you are inside the Python environment. means you are inside the Python environment.
import pyttsx3
engine = pyttsx3.init()
engine.say("Twinkle Twinkle Little Star")
For Windows users
use this program
engine.runAndWait()