English
Open in Telegram

Post✅Python Interview Questions with Answers 🧑‍💻👩‍💻

2 November 2025
C
Codehub
✅Python Interview Questions with Answers 🧑‍💻👩‍💻 1️⃣ Write a function to remove outliers from a list using IQR. import numpy as np def remove_outliers(data): q1 = np.percentile(data, 25) q3 = np.percentile(data, 75) iqr = q3 - q1 lower = q1 - 1.5 * iqr upper = q3 + 1.5 * iqr return [x for x in data if lower <= x <= upper] 2️⃣ Convert a nested list to a flat list. nested = [[1, 2], [3, 4],] flat = [item for sublist in nested for item in sublist] 3️⃣ Read a CSV file and count rows with nulls. import pandas as pd df = pd.read_csv('data.csv') null_rows = df.isnull().any(axis=1).sum() print("Rows with nulls:", null_rows) 4️⃣ How do you handle missing data in pandas? ⦁ Drop missing rows: df.dropna() ⦁ Fill missing values: df.fillna(value) ⦁ Check missing data: df.isnull().sum() 5️⃣ Explain the difference between loc[] and iloc[]. ⦁ loc[]: Label-based indexing (e.g., row/column names) Example: df.loc[0, 'Name'] ⦁ iloc[]: Position-based indexing (e.g., row/column numbers) Example: df.iloc 💬 Tap ❤️ for more!
14 · 7.2K ·

Nearby in the feed

CCodehub🔥 Master These 30 Algorithms to Boost Your Coding Skills! 🚀 - Binary Search 🕵️‍♂️ - Quick Sort ⚡ - Merge Sort 🌊 - Heap Sort 🏰 - BFS 🌐 - DFS 🌲 - Dijkstra’s ShortCCodehub🚀 𝗕𝗲𝗰𝗼𝗺𝗲 𝗮𝗻 𝗔𝗜/𝗟𝗟𝗠 𝗘𝗻𝗴𝗶𝗻𝗲𝗲𝗿: 𝗖𝗲𝗿𝘁𝗶𝗳𝗶𝗰𝗮𝘁𝗶𝗼𝗻 𝗣𝗿𝗼𝗴𝗿𝗮𝗺 𝗠𝗮𝘀𝘁𝗲𝗿 𝘁𝗵𝗲 𝘀𝗸𝗶𝗹𝗹𝘀 𝘁𝗲𝗰𝗵 𝗰𝗼𝗺𝗽𝗮𝗻𝗶𝗲𝘀 𝗮𝗿𝗲 𝗵𝗶𝗿𝗶𝗻𝗴 𝗳𝗼𝗿: fine-tune large language models and deploy them to productio
this message
CCodehub✅Python Interview Questions with Answers 🧑‍💻👩‍💻 1️⃣ Write a function to remove outliers from a list using IQR. import numpy as np def remove_outliers(data): q1
CCodehubCodehub@pythonadvisorai · channel
31 653subscribers1 028posts in the index
Venue feed Open in Telegram

An open public feed from the search index ChatCrawler — “Google for public Telegram”; refreshed as the venue is crawled. Times are UTC.

Public content only, official Telegram API. About · FAQ · Index limits · Remove a page · Catalog · Search · How we count