0% found this document useful (0 votes)
3 views2 pages

Python Imp Notes

Uploaded by

Amruta Shingote
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views2 pages

Python Imp Notes

Uploaded by

Amruta Shingote
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

PYTHON VERY SHORT NOTES

UNIT 1:

- Python: High-level, interpreted language

- Data Types: int, float, bool, str, list

- Variables: No declaration needed

- Operators: +, -, *, /, %, ==, !=, >, <

- Expressions: combination of variables & operators

- Statements: instructions (if, print, assignment)

- Functions: reusable code blocks

- Modules: .py files (import module)

UNIT 2:

- Boolean: True / False

- if: decision making

- if-else: two conditions

- if-elif-else: multiple conditions

- Loops: while, for

- break: exit loop

- continue: skip iteration

- pass: empty statement

UNIT 3:

- Functions: def keyword

- Return: gives output

- Parameters vs Arguments

- Types: with/without return & parameters

- Scope: Local & Global

- Recursion: function calls itself

- Strings: immutable

- Arrays: collection of elements

UNIT 4:
- List: ordered, mutable

- Tuple: ordered, immutable

- Dictionary: key-value pairs

- List comprehension: short syntax

UNIT 5:

- Files: read/write data

- Exceptions: error handling

- try-except: handle errors

- Modules: datetime, math, os

- Packages: collection of modules

You might also like