Python Data Science Jobs & Interviews
19.6K subscribers
181 photos
4 videos
24 files
288 links
Your go-to hub for Python and Data Scienceβ€”featuring questions, answers, quizzes, and interview tips to sharpen your skills and boost your career in the data-driven world.

Admin: @Hussein_Sheikho
Download Telegram
Python Question / Quiz;

What is the output of the following Python code, and why? πŸ€”πŸš€ Comment your answers below! πŸ‘‡

#python #programming #developer #programmer #coding #coder #softwaredeveloper #computerscience #webdev #webdeveloper #webdevelopment #pythonprogramming #pythonquiz #ai #ml #machinelearning #datascience

https://t.iss.one/DataScienceQ
πŸ‘4
Python Question / Quiz;

What is the output of the following Python code, and why? πŸ€”πŸš€ Comment your answers below! πŸ‘‡

#python #programming #developer #programmer #coding #coder #softwaredeveloper #computerscience #webdev #webdeveloper #webdevelopment #pythonprogramming #pythonquiz #ai #ml #machinelearning #datascience

https://t.iss.one/DataScienceQ
πŸ‘2
Python Question / Quiz;

What is the output of the following Python code, and why? πŸ€”πŸš€ Comment your answers below! πŸ‘‡

#python #programming #developer #programmer #coding #coder #softwaredeveloper #computerscience #webdev #webdeveloper #webdevelopment #pythonprogramming

https://t.iss.one/DataScienceQ
πŸ‘4❀1
Python Question / Quiz;

What is the output of the following Python code, and why? πŸ€”πŸš€ Comment your answers below! πŸ‘‡

#python #programming #developer #programmer #coding #coder #softwaredeveloper #computerscience #webdev #webdeveloper #webdevelopment #pythonprogramming

https://t.iss.one/DataScienceQ
πŸ‘2❀1
What will be the output of the following code?

import numpy as np
numbers = np.array([1, 2, 3])
new_numbers = numbers + 1
print(new_numbers.tolist())


#python #programming #developer #programmer #coding #coder #softwaredeveloper #computerscience #webdev #webdeveloper #webdevelopment #pythonprogramming

https://t.iss.one/DataScienceQ
πŸ‘2
Python Question / Quiz;

What is the output of the following Python code, and why? πŸ€”πŸš€ Comment your answers below! πŸ‘‡

#python #programming #developer #programmer #coding #coder #softwaredeveloper #computerscience #webdev #webdeveloper #webdevelopment #pythonprogramming #pythonquiz #ai #ml #machinelearning #datascience

https://t.iss.one/DataScienceQ
πŸ‘3
Python Question / Quiz;

What is the output of the following Python code, and why? πŸ€”πŸš€ Comment your answers below! πŸ‘‡

#python #programming #developer #programmer #coding #coder #softwaredeveloper #computerscience #webdev #webdeveloper #webdevelopment #pythonprogramming

https://t.iss.one/DataScienceQ
πŸ‘2
🧠 What is a Generator in Python?
A generator is a special type of iterator that produces values lazilyβ€”one at a time, and only when neededβ€”without storing them all in memory.

---

❓ How do you create a generator?
βœ… Correct answer:
Option 1: Use the yield keyword inside a function.

πŸ”₯ Simple example:

def countdown(n):
while n > 0:
yield n
n -= 1


When you call this function:

gen = countdown(3)
print(next(gen)) # 3
print(next(gen)) # 2
print(next(gen)) # 1


Each time you call next(), the function resumes from where it left off, runs until it hits yield, returns a value, and pauses again.

---

β›” Why are the other options incorrect?

- Option 2 (class with __iter__ and __next__):
It works, but it’s more complex. Using yield is simpler and more Pythonic.

- Options 3 & 4 (for or while loops):
Loops are not generators themselves. They just iterate over iterables.

---

πŸ’‘ Pro Tip:
Generators are perfect when working with large or infinite datasets. They’re memory-efficient, fast, and clean to write.

---

πŸ“Œ #Python #Generator #yield #AdvancedPython #PythonTips #Coding


πŸ”By: https://t.iss.one/DataScienceQ
πŸ‘6❀2πŸ”₯2❀‍πŸ”₯1
Question 1 (Intermediate):
In Python, which of these is the correct way to create a virtual environment?

A) python create venv
B) python -m venv myenv
C) pip install virtualenv
D) conda make env

#Python #Development #VirtualEnv #Coding
❀2
πŸ”₯ Trending Repository: tech-interview-handbook

πŸ“ Description: πŸ’― Curated coding interview preparation materials for busy software engineers

πŸ”— Repository URL: https://github.com/yangshun/tech-interview-handbook

🌐 Website: https://www.techinterviewhandbook.org

πŸ“– Readme: https://github.com/yangshun/tech-interview-handbook#readme

πŸ“Š Statistics:
🌟 Stars: 130K stars
πŸ‘€ Watchers: 2.2k
🍴 Forks: 15.8K forks

πŸ’» Programming Languages: TypeScript - JavaScript - Python

🏷️ Related Topics:
#algorithm #algorithms #interview_practice #interview_questions #coding_interviews #interview_preparation #system_design #algorithm_interview #behavioral_interviews #algorithm_interview_questions


==================================
🧠 By: https://t.iss.one/DataScienceM
❀1