Written by students who passed Immediately available after payment Read online or as PDF Wrong document? Swap it for free 4.6 TrustPilot
logo-home
Class notes

Python

Rating
-
Sold
-
Pages
5
Uploaded on
20-02-2026
Written in
2025/2026

Python Introduction – Python is an easy programming language used to communicate with computers. Features of Python – Python is simple, readable, and works on many platforms. Applications of Python – Python is used for websites, AI, data analysis, games, and automation. Print Statement – print() is used to display output on the screen. Comments – Comments are notes in code that Python ignores. Variables – Variables are containers used to store data values. Naming Rules for Variables – Variable names must follow rules like starting with a letter and having no special symbols. Data Types – Data types define the kind of value stored, like int, float, string, or boolean. Type Conversion – Type conversion changes one data type into another. Input from User – input() is used to take data from the user. Output Formatting – Output formatting helps display results in a clear and readable way. Arithmetic Operators – Arithmetic operators perform mathematical operations like addition and subtraction. Comparison Operators – Comparison operators compare two values and return True or False. Logical Operators – Logical operators combine multiple conditions. Assignment Operators – Assignment operators assign or update variable values. If Statement – If statement checks a condition and runs code if it is true. If–Else Statement – If–else runs one block if true and another if false. If–Elif–Else Ladder – It checks multiple conditions one by one. Nested If – Nested if is an if statement inside another if statement. For Loop – For loop repeats code a fixed number of times. While Loop – While loop repeats code as long as a condition is true. Nested Loops – Nested loops are loops placed inside another loop. Break Statement – Break stops a loop immediately. Continue Statement – Continue skips the current loop iteration. Pass Statement – Pass is a placeholder that does nothing. Strings – Strings are text values written inside quotes. String Indexing – String indexing accesses characters using position numbers. String Slicing – String slicing extracts part of a string. String Methods – String methods are built-in functions used to modify strings. Lists – Lists are ordered and changeable collections of items. List Indexing – List indexing accesses items using position numbers. List Slicing – List slicing extracts a portion of a list. List Methods – List methods are built-in functions like append and remove. Tuples – Tuples are ordered collections that cannot be changed. Tuple Characteristics – Tuples are immutable and use parentheses. Sets – Sets are unordered collections of unique values. Set Operations – Set operations perform union, intersection, and difference. Dictionaries – Dictionaries store data in key–value pairs. Dictionary Methods – Dictionary methods help access and modify key–value data. Functions – Functions are reusable blocks of code. Function Parameters and Arguments – Parameters receive values and arguments pass values to functions. Return Statement – Return sends a value back from a function. Scope of Variables – Scope defines where a variable can be used. Lambda Functions – Lambda functions are small one-line anonymous functions. Exception Handling – Exception handling prevents program crashes due to errors. Modules – Modules are files containing reusable Python code. Import Statement – Import is used to include a module in a program. Built-in Modules – Built-in modules like math and random provide ready-made functions. File Handling – File handling is used to read, write, or modify files. Object-Oriented Programming Basics – OOP is a way of programming using classes and objects. Class – A class is a blueprint for creating objects. Object – An object is an instance of a class. Constructor (init) – A constructor initializes object values when it is created. Instance Variables – Instance variables store data specific to an object. Methods – Methods are functions defined inside a class.

Show more Read less
Institution
Course

Content preview

BASICS of Python (Super Easy Notes)

1. What is Python?

Python is a programming language.
It is used to:

Build websites🌐
Create apps 📱

Do data analysis 📊

Make games 🎮

AI & Machine Learning 🤖
Python is easy because it looks almost like English.

Example:

print("Hello")

It simply prints Hello on the screen.


---

2. Variables (Like Storage Boxes 📦)
A variable stores data.

Example:

name = "Velvet"
age = 18

Here:

name stores text

age stores number


You can use it like:

, print(name)


---

3. Data Types (Types of Data)

Python has different types of data:

Type​ Example​ Meaning

int​ 10​ Whole number
float​ 3.14​ Decimal number
str​ "Hi"​ Text
bool​ True​ True/False


Example:

x=5 # int
y = 2.5 # float
z = "Hello" # string
a = True # boolean


---

4.Taking Input from User 🗣️
If you want the user to enter something:

name = input("Enter your name: ")
print("Hello", name)

⚠️ Important: Input always comes as text (string).
If you want number:

age = int(input("Enter age: "))


---

5. If–Else (Decision Making 🤔)
Python can make decisions.

Example:

Written for

Institution
Secondary school
Course
School year
1

Document information

Uploaded on
February 20, 2026
Number of pages
5
Written in
2025/2026
Type
Class notes
Professor(s)
Suguna
Contains
All classes

Subjects

$8.49
Get access to the full document:

Wrong document? Swap it for free Within 14 days of purchase and before downloading, you can choose a different document. You can simply spend the amount again.
Written by students who passed
Immediately available after payment
Read online or as PDF

Get to know the seller
Seller avatar
nekasakthivel

Get to know the seller

Seller avatar
nekasakthivel
Follow You need to be logged in order to follow users or courses
Sold
-
Member since
2 months
Number of followers
0
Documents
2
Last sold
-

0.0

0 reviews

5
0
4
0
3
0
2
0
1
0

Recently viewed by you

Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their tests and reviewed by others who've used these notes.

Didn't get what you expected? Choose another document

No worries! You can instantly pick a different document that better fits what you're looking for.

Pay as you like, start learning right away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and aced it. It really can be that simple.”

Alisha Student

Working on your references?

Create accurate citations in APA, MLA and Harvard with our free citation generator.

Working on your references?

Frequently asked questions