Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Santosh771/python_repo

Open more actions menu
 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

60 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Programming Language

Languages in the main medium for communicating between the computer systems. A program is collection of instructions that can be executed by a computer to perform a specific task.

What is Python? Python is a high-level, versatile programming language that emphasizes simplicity and readability. It is widely used across various domains for tasks ranging from scripting to advanced machine learning.

******************************************************************* Key Points to Explain Python ***************************************************************************

  1. Introduction -

Created by Guido van Rossum and first released in 1991. Named after the comedy series "Monty Python's Flying Circus", not the snake.

  1. Features-

Simple and Readable: Focused on easy-to-understand syntax. Interpreted: Executes code line-by-line without compiling. Dynamically Typed: No need to declare variable types explicitly. Object-Oriented: Supports OOP principles like inheritance and polymorphism. Extensive Standard Library: Offers tools for string manipulation, file handling, networking, and more. Cross-platform: Runs on major operating systems (Windows, macOS, Linux).

  1. Applications-

Web Development: Frameworks like Django and Flask. Data Science & AI: Libraries like NumPy, Pandas, TensorFlow, and Scikit-learn. Scripting & Automation: Used to automate repetitive tasks. Game Development: Frameworks like Pygame. Desktop Applications: Using libraries like Tkinter or PyQt. IoT Development: Works seamlessly with hardware like Raspberry Pi.

  1. Advantages : Beginner-friendly. Huge community support. Open-source and free. Rapid development due to simple syntax. Integration capabilities with C/C++ and other languages.

  2. Disadvantages : Slower execution compared to compiled languages like C++. Not ideal for low-level programming (e.g., device drivers).

Python is Open Source When we say Python is open-source, it means:

Free to Use:-

Python is available for anyone to download, use, and modify without any cost. It can be used for both personal and commercial purposes without licensing fees.

Source Code is Publicly Available:-

Python's source code is accessible to everyone through platforms like the Python GitHub repository. Developers can view, edit, and enhance the code as per their requirements.

Python is primarily an interpreted language, but it also has elements of compilation in its execution process. Let’s break it down:

How Python Works: Source Code to Bytecode (Compilation Phase):

When you run a Python script, the Python interpreter first compiles the source code (.py files) into an intermediate format called bytecode. This bytecode is a platform-independent, low-level representation of the code. The bytecode is stored temporarily in memory or as a .pyc file (in the pycache directory) for future use. Bytecode Execution (Interpretation Phase):

The compiled bytecode is executed by the Python Virtual Machine (PVM), which is the interpreter. The PVM translates bytecode into machine code specific to the host system and executes it.

Why is Python Considered Interpreted?

Python executes the bytecode using an interpreter (PVM) at runtime, which gives it its interpreted nature. You do not need to manually compile Python code; the compilation to bytecode happens automatically and transparently. Key Characteristics: No Explicit Compilation:

Unlike languages like C or Java, where you compile code manually, Python handles the compilation internally. Platform Independence:

Python’s bytecode can run on any system with a compatible Python interpreter, making it cross-platform. Dynamic Typing:

Python determines variable types at runtime, a feature typically associated with interpreted languages.

Comparison with Compiled Languages Aspect Compiled Languages (e.g., C) Interpreted Languages (e.g., Python) Execution Speed Faster Slower (due to runtime interpretation) Compilation Step Manual (source to machine code) Automatic (source to bytecode) Portability Limited to compiled platform Highly portable (via interpreter)

About

code repo for python

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%
Morty Proxy This is a proxified and sanitized view of the page, visit original site.