Python Pandas 🐼
❤5
Python PIP Cheatsheet 👆
❤7👍2
🧿 Top 10 VS Code Extensions 📚👨💻
✨ Prettier - Clean, consistent auto-formatting
🧩 Bracket Pair Colorizer - Color-coded brackets
⚡️ Live Server - Auto-refresh websites as you code
📸 CodeSnap - Snap stunning code screenshots
🖤 Aura Theme - Sleek dark mode for your editor
🎨 Material Icon Theme - Colorful file icons, easy nav
🤖 GitHub Copilot - AI code buddy with smart suggestions
⚙️ ESLint - Catch and fix errors on the fly
🚀 Tabnine - Speed up coding with AI autocomplete
🔍 Path Intellisense - Auto path imports, zero hassle
React ❤️ for more like this
✨ Prettier - Clean, consistent auto-formatting
🧩 Bracket Pair Colorizer - Color-coded brackets
⚡️ Live Server - Auto-refresh websites as you code
📸 CodeSnap - Snap stunning code screenshots
🖤 Aura Theme - Sleek dark mode for your editor
🎨 Material Icon Theme - Colorful file icons, easy nav
🤖 GitHub Copilot - AI code buddy with smart suggestions
⚙️ ESLint - Catch and fix errors on the fly
🚀 Tabnine - Speed up coding with AI autocomplete
🔍 Path Intellisense - Auto path imports, zero hassle
React ❤️ for more like this
👍5❤1
Python Cheatsheet ♥️
1. Common Data Types
int, float – numbers
str – text
list – ordered, changeable collection
dict – key-value pairs
tuple – like list, but unchangeable
set – unique, unordered items
2. Essential Functions
print() – display output
type() – check data type
len() – count items
range() – generate numbers
input() – take user input
3. String Methods
.upper(), .lower() – change case
.strip() – remove whitespace
.replace() – swap text
.split() – break into list
4. List Methods
append() – add item
pop() – remove item
sort() – sort list
[1:4] – slicing (get part of list)
5. Dictionary Basics
Access: mydict['key']
Safe access: mydict.get('key')
Add/Update: mydict['new'] = value
6. Control Flow
if / elif / else – conditions
for – loop over items
while – loop with condition
break / continue – control loop
7. Functions
def – define a function
return – return a value
lambda – short anonymous function
8. Useful Built-in Modules
math – sqrt, pi, round
random – random numbers, choices
datetime – current date/time
os – system & file handling
9. Popular Libraries for Data Work
NumPy – numerical operations
Pandas – dataframes and analysis
Matplotlib
React with ❤️ for more useful Cheatsheets
#python
1. Common Data Types
int, float – numbers
str – text
list – ordered, changeable collection
dict – key-value pairs
tuple – like list, but unchangeable
set – unique, unordered items
2. Essential Functions
print() – display output
type() – check data type
len() – count items
range() – generate numbers
input() – take user input
3. String Methods
.upper(), .lower() – change case
.strip() – remove whitespace
.replace() – swap text
.split() – break into list
4. List Methods
append() – add item
pop() – remove item
sort() – sort list
[1:4] – slicing (get part of list)
5. Dictionary Basics
Access: mydict['key']
Safe access: mydict.get('key')
Add/Update: mydict['new'] = value
6. Control Flow
if / elif / else – conditions
for – loop over items
while – loop with condition
break / continue – control loop
7. Functions
def – define a function
return – return a value
lambda – short anonymous function
8. Useful Built-in Modules
math – sqrt, pi, round
random – random numbers, choices
datetime – current date/time
os – system & file handling
9. Popular Libraries for Data Work
NumPy – numerical operations
Pandas – dataframes and analysis
Matplotlib
React with ❤️ for more useful Cheatsheets
#python
❤4
10 Python Concepts Every Developer Should Know
✅ List Comprehensions – Write cleaner loops in a single line
✅ Lambda Functions – Anonymous functions for quick operations
✅ Decorators – Add functionality to functions without changing them
✅ Generators & Iterators – Handle large data efficiently with lazy evaluation
✅ OOP (Classes & Inheritance) – Build scalable, reusable code
✅ Exception Handling – Write error-proof programs with try-except blocks
✅ Modules & Packages – Organize your code like a pro
✅ Virtual Environments (venv) – Keep dependencies isolated per project
✅ File Handling (with open) – Read/write files securely
✅ Type Hinting – Make your code more readable and less error-prone
Free Python Resources: 👇 https://whatsapp.com/channel/0029VaiM08SDuMRaGKd9Wv0L
✅ List Comprehensions – Write cleaner loops in a single line
✅ Lambda Functions – Anonymous functions for quick operations
✅ Decorators – Add functionality to functions without changing them
✅ Generators & Iterators – Handle large data efficiently with lazy evaluation
✅ OOP (Classes & Inheritance) – Build scalable, reusable code
✅ Exception Handling – Write error-proof programs with try-except blocks
✅ Modules & Packages – Organize your code like a pro
✅ Virtual Environments (venv) – Keep dependencies isolated per project
✅ File Handling (with open) – Read/write files securely
✅ Type Hinting – Make your code more readable and less error-prone
Free Python Resources: 👇 https://whatsapp.com/channel/0029VaiM08SDuMRaGKd9Wv0L
👍4
How to convert image to pdf in Python
# Python3 program to convert image to pfd
# using img2pdf library
# importing necessary libraries
import img2pdf
from PIL import Image
import os
# storing image path
img_path = "Input.png"
# storing pdf path
pdf_path = "file_pdf.pdf"
# opening image
image = Image.open(img_path)
# converting into chunks using img2pdf
pdf_bytes = img2pdf.convert(image.filename)
# opening or creating pdf file
file = open(pdf_path, "wb")
# writing pdf files with chunks
file.write(pdf_bytes)
# closing image file
image.close()
# closing pdf file
file.close()
# output
print("Successfully made pdf file")
pip3 install pillow && pip3 install img2pdf
👍6👏2❤1