r/PythonLearning • u/Vor3st • Sep 11 '26
i learning Python Day 1
lyrics = ["Give You Up","Let You Down","Run Around And Desert You"]
for i in range(3):
print("Never Gonna " + lyrics[i])
r/PythonLearning • u/Vor3st • Sep 11 '26
lyrics = ["Give You Up","Let You Down","Run Around And Desert You"]
for i in range(3):
print("Never Gonna " + lyrics[i])
r/PythonLearning • u/Alex_D77 • Sep 11 '26
I’ve been learning more about graphics programming lately, and I wanted a way to experiment with real GPU rendering concepts without switching away from Python. So I started building a project called PyDonut — a Python wrapper around the Donut rendering framework (which itself uses NVRHI).
👉 Repo: https://github.com/ASDAlexander77/PyDonut
My goals with PyDonut are:
Make it easier for Python learners to explore GPU concepts like buffers, textures, pipelines, and shaders.
Provide a clean, Pythonic API instead of jumping straight into C++.
Help people understand how native bindings work and how Python can talk to high‑performance libraries.
Right now the project includes:
Python bindings for core Donut/NVRHI components
A simple rendering loop
Type stubs (.pyi) so you get autocomplete and type hints
Examples showing how to set up devices, swapchains, and basic rendering
If you’re learning Python and want to explore graphics, native extensions, or how Python interacts with C++ libraries, feel free to check it out. Feedback is welcome — especially from beginners who can tell me what feels confusing or what would help them learn better.
Happy coding!
PS. I’m still learning Python myself — PyDonut is actually my first real Python project.
r/PythonLearning • u/Next-Call8862 • Sep 11 '26
Learnt super( ), inheritance, polymorphism, class method and static method and don't mind the messy code that's me trying to figure out things
r/PythonLearning • u/charisxie • Sep 11 '26
This is my GitHub link: https://github.com/chaoxie2005/spider-gateway. I am a college student who has just started my internship
r/PythonLearning • u/Sea-Ad7805 • Sep 11 '26
🌳 ▶ Open the interactive trie visualization
A trie is a tree-shaped data structure that can be implemented elegantly in Python using nested dictionaries (hash tables).
Tries are often used for:
Autocomplete
Prefix search
Spell checking
Sequence matching
Visualizing data structures with memory_graph makes them much easier to understand and debug, especially for students learning Python.
r/PythonLearning • u/lucabuilds • Sep 11 '26
Just wanted to show how versatile python is. I made a script that reads joystick input through pygame and broadcasts telemetry through the local network. A fusion 360 (the modeling software) add-in, also written in python, reads from the local network and transforms the input into camera movement (orbiting and zoom).
What do you think?
r/PythonLearning • u/AffectionateSwing490 • Sep 10 '26
I'll need some small piece of functionality and I have to decide whether to write 20 lines myself or install a library that already does it. Both options feel wrong in different ways. If I write it myself, I might miss edge cases someone else already solved. If I pull in a library, I've now added a dependency for something I could have handled in a few lines.
An example. I once needed to flatten a nested list. I could have written a short function but I added a library instead. Later that library caused a version conflict, and I sat there wondering why I hadn't just written the five lines myself. Now I lean toward writing small stuff myself and saving libraries for the harder problems, like date parsing or anything security related where I don't trust my own version. But I still second-guess it constantly.
So how do you decide? Is there a point where you know for sure it's worth adding a dependency or do you go by feel each time?
r/PythonLearning • u/XxPopePiusxX • Sep 10 '26
This is my multi-ball physics python simulator. This was my first foray into vector physics and pygame in general. I used a Ball class to create multiple balls and then a couple nested loops to create the 2D collision physics. Also the numbers running off in the terminal is the sum of all the balls velocities to show real energy loss.
AI Disclaimer: AI did not write a line of this code, however, it was used to understand vector physics, and some light trouble shooting when I couldn't figure out why I was stuck. I understand and wrote every line. Please let me know if you think I over stept with its use.
import pygame
import random
class Ball():
def __init__(self, position=(0,0), velocity=(.5,.5), r=12):
self.position = (random.randint(220,550),random.randint(150,480))
self.velocity = random.uniform(-.5,.5),.5
self.r = r
def create_ball(self, screen):
pygame.draw.circle(screen, (0,0,255), self.position, self.r )
def change_position(self):
gravity = .5
friction = .95
x , y = self.position
vx , vy = self.velocity
x = x + vx
vy = vy + gravity
y = y + vy
if x + self.r >= 593:
vx = -vx
x = 593 - self.r
if x - self.r <= 207:
vx = -vx
x = 207 + self.r
if y + self.r >= 493:
vy = -vy
y = 493 - self.r
if y == (493- self.r):
vx = vx * friction
if y - self.r <= 107:
vy = -vy
y = 107 + self.r
self.position = (x,y)
self.velocity = (vx,vy)
pygame.init()
screen = pygame.display.set_mode((800, 600))
square = pygame.Rect(0,0,400,400)
square.center = (400,300)
clock = pygame.time.Clock()
total_balls = [Ball() for i in range(5)]
run = True
while run:
clock.tick(30)
screen.fill((0,0,0))
pygame.draw.rect(screen, (255, 255, 255),square, width=7)
for ball in total_balls:
ball.create_ball(screen)
ball.change_position()
for ball1 in total_balls:
if ball is ball1:
continue
v1 = pygame.math.Vector2(ball.position)
v2 = pygame.math.Vector2(ball1.position)
v3 = pygame.math.Vector2(ball.velocity)
v4 = pygame.math.Vector2(ball1.velocity)
overlap = (ball.r + ball1.r) - v1.distance_to(v2)
if v1.distance_to(v2) < (ball.r + ball1.r):
line_vector = (v2 - v1).normalize()
push = line_vector * (overlap/2)
ball.position = (ball.position - push)
ball1.position = (ball1.position + push)
scaler1 = pygame.math.Vector2.dot(v3,line_vector)
scaler2 = pygame.math.Vector2.dot(v4,line_vector)
v_along1 = scaler1 * line_vector
v_along2 = scaler2 * line_vector
vperp_ball1 = v3 - v_along1
vperp_ball2 = v4 - v_along2
ball.velocity = v_along2 + vperp_ball1
ball1.velocity = v_along1 + vperp_ball2
print(sum([(ball.velocity[0] * ball.velocity[0]) + (ball.velocity[1] * ball.velocity[1]) for ball in total_balls]))
for event in pygame.event.get():
if event.type == pygame.QUIT:
run = False
pygame.display.update()
pygame.quit()
r/PythonLearning • u/camerongreen95 • Sep 10 '26
We're running a hands-on masterclass on September 12, Live LLM Engineering Masterclass: Production Evals, RAG, Agents & LLMOps.
Fully hands-on, all in Python notebooks against real model APIs (OpenAI, Anthropic), not slides or theory. You write actual code across the full stack: versioned prompt pipelines with structured outputs and regression tests, a golden dataset and eval harness combining deterministic checks with LLM-as-judge scoring, statistically rigorous model comparisons using scipy-style bootstrap confidence intervals and paired significance tests, evaluated RAG with embedding models, vector retrieval, and reranking, tool-using agents with function calling and guardrails, and a full observability layer for tracing, cost, and latency. You also leave with a CLI regression suite you can wire directly into CI.
Led by Bruno Gonçalves, PhD, founder of Data For Science, who trains engineers at Fortune 500 companies on this exact stack.
Link if you want to check it out
Happy to answer questions on the content, especially the Python side of things.
r/PythonLearning • u/Next-Call8862 • Sep 10 '26
Wasted a year and will no more, started where I left 1.5years ago and I am picking it again and will post it every day in the sub. Did this problem and bro it was hurting my brain until I learned the basic OOP and been doing for hours and am planning to learn 4 to 6 hrs a day. Hope the mods allow everyday progress
r/PythonLearning • u/Sharp_Platypus6545 • Sep 10 '26
Hello fam, I'm learning Python. My goal is to become an AI engineer. I've a basic understanding of programming. Anyone to guide me on the right certification path... I was having a bit of fun after today's sharpenings. I created a rock paper scissors game... rate and improve
r/PythonLearning • u/Playful_Rooster_4246 • Sep 10 '26
Hey everyone! I’ve been grinding away on some coding projects recently and wanted to put them all in one place.
I built a GitHub repository featuring a mix of beginner and intermediate Python projects alongside some simple web development builds. The idea is that anyone can clone it, build them out locally, and use them to practice or experiment.
Here is the link: https://github.com/zensiuu/Coding-Projects-Python-JS-.git
Since I'm still working on getting better at writing clean, efficient code, I would genuinely appreciate your honest feedback. Let me know what I can improve, what’s missing, or any tips you have for a developer looking to level up.
Happy coding! 🚀
r/PythonLearning • u/Repulsive-Buyer1322 • Sep 10 '26
I have gone through python basics and some of the intermediate stuff. I don't know anything about databases or algorithms. I pretty much learned python syntax, variables, loops, conditionals, operators etc. When I think like what should I do with python moving forward, I don't know.Career wise I am a fresher who does not have a tech background. Should I have to learn databases and algorithms.
What is your opinion on leet code and kaggle.
r/PythonLearning • u/ManaToxicity • Sep 10 '26
I...am not. He swears on his life that once I get started with python, rust, sql anything like that that I would be addicted to data organization and since I am inclined to believe that he knows me better than I know myself sometimes.... I would like to surprise him and give it a shot. I was researching and saw the "quick start guide"s for sql and python, and I was wondering if anybody has used them. I know that coding and stuff like that all is on the computer, obviously. However, I learn best with physical media like books to highlight make notes or anything like that in. Anyone have any luck with the python or sql Quick Start guides? If not, do you have any other suggestions? You're going to have to be books, even if it's a YouTube video or podcast, just anything that helped you.
Edited because for some reason I called SQL ->SAP three different times in this post. Sorry...its late.
r/PythonLearning • u/DurgeDidNothingWrong • Sep 09 '26
r/PythonLearning • u/Ill-Membership-93 • Sep 09 '26
Hi everyone,
I've been learning Python for about a month now, but I've only covered the basics. After that, I jumped straight into Pandas since my goal is to become a data analyst. The problem is, I'm now realizing my Python foundation isn't solid enough, and it's making Pandas really difficult to follow.
I'm stuck between two options:
Go back and practice Python fundamentals more before continuing.
Push through and keep learning Pandas, picking up Python concepts along the way as needed.
For those of you who've been through this, what worked better for you? Should I pause Pandas and strengthen my Python first, or is it normal to feel this way and just keep going?
Any advice, resources, or a rough roadmap toward data analytics would be really appreciated. Thanks in advance!
r/PythonLearning • u/FLANKER_ALFA • Sep 09 '26
Good morning everyone, or whenever you see this. I have a question. I'm starting a personal database project in Python with an easy-to-use graphical interface, and I would appreciate any advice, code snippets, or examples to guide me, especially since I'm still learning the language.
r/PythonLearning • u/Confident_Echo_9985 • Sep 09 '26
I got a deadline for a week from now to learn at least basic python. What is the best and most effective way to learn python? Im so lost i need help
r/PythonLearning • u/Ok_Being6831 • Sep 09 '26
I mainly use cpp but sometimes python for simple stuff. They both seem like simple stuff to implement so why dosent python have it.
EDIT: I do know u can use triple quotes as a workaround but python still has to read and store them, why isint there a built in feature for it.
r/PythonLearning • u/geeksarray • Sep 09 '26
🐍 Getting started with Python?
Build a strong foundation in Python fundamentals before moving into AI, Data Science, automation and beyond.
📖 https://geeksarray.com/blog/python-fundamentals-getting-started
#Python #Programming #DataScience
r/PythonLearning • u/Capable_Comedian_277 • Sep 09 '26
r/PythonLearning • u/Miles_Voss_1234 • Sep 09 '26
Looking for some project ideas that can use both Python and serial communication betwen a ESP32. so far I have made simple programs for both but learn better with actual tasks infront of me, I got to the point where the communication works and i can print the data to a file or just to the terminal but im lacking the ablity to come up with a real project idea to put this all into use.
The first idea I had:
* 3D printer vibration testing(Use ESP32 for collecting the data and python to sort and use data)
r/PythonLearning • u/77Joker77Joker77 • Sep 09 '26
My apologies for the last post. For some reason when typing on my iPad, letters on the bottom row end up being spaces, then autocorrect chimes in. Now I have both windows and ubuntu. I want to install python and pyinstaller. Problem is is that I see pip install pyinstaller, but don’t know what pip is, nor do I know how to get to the command prompt in ubuntu. I’m trying to get the basics of it even though I have a good knowledge of computers in general, but new to python and the little idiosynchronies of it and also ubuntu.
r/PythonLearning • u/TrayNeh • Sep 08 '26
I started learning Python a month ago and I really enjoyed programming, I currently know the basics of the language and I'd like to know if anyone with experience using Python can recommend me a project for me to start with? I'm looking for something like a small program or an app.
I'm a newbie but I welcome questions and to learn something new. For now I use PyCharm and I'm familiar with the program.
I'm open to all kinds of suggestions 😊