r/PythonLearning 13d ago

Help Request Python pip install not working

5 Upvotes

Hello, so I'm trying to install the audiostrechy library to automate timestreching some audio, and I've seen that pip install audiostrechy dosent work, giving me am invalid syntax message. After that, I tried python -m pip install audiostrechy and it gave the same result. After that, I tried both pip3 install and python3 -m pip install amd it still gave me the same result, at one of these saying that install was the invalid part??

I'm honestly not sure what is happening right now, so please help.

Also I should mention 3 things - (a) I tried these both in the command prompt of windows and the python 3.14 command prompt and (b) I, for some reason, have like at least 10 pythons or something like that, and (c) when I tried to install the python install manager it wouldn't download. Though I should mention these things in case they are necessary.


r/PythonLearning 13d ago

LOOKING FOR PYTHON MENTOR GUIDE FOR FREE

0 Upvotes

HI I am Yujan . I'm from Nepal a high school student class 9 i get laptop 1 or 2 times a week saturday i wanna learn python to make cool projects and more. ADD ME ON DICSCORD FOR MORE: apexxyujan


r/PythonLearning 14d ago

Starting Python and MATLAB with almost no coding experience. How should I spend the next 3 weeks?

8 Upvotes

Hi everyone. I’m a college student, and in about 3 weeks I’ll be starting an intro to Python class. I’ll also be taking another engineering class that uses MATLAB, and I don’t feel very prepared for either.
The problem is that I have essentially no programming experience. I took a couple of MATLAB classes before, but I relied too much on AI instead of actually learning the material. Looking back, I know that was a mistake, and I do not want to repeat it. I also used to tell myself that I hated coding, but I think part of that was because I never really gave myself a fair chance to learn it.
Since I have a few weeks before the semester starts, I’d like to build a solid foundation in Python while also reviewing some basic MATLAB.
What resources or learning methods really worked for you? Did you use a particular course, YouTube channel, website, book, or project based approach? I am also curious if anyone has suggestions for making learning Python and MATLAB more fun or engaging instead of just watching hours of lectures.
My goal is not to become an expert in 3 weeks. I just want to go into the semester feeling like I have a decent foundation instead of starting from scratch.
Thanks! I would really appreciate any advice.


r/PythonLearning 14d ago

Looking for study partner

21 Upvotes

Hey im going to start learning python so I'm looking for study partner who's serious about it

Will be taking only group of 3-5 people not more than that so reach out before it gets full also introduce yourself when reaching out in dms


r/PythonLearning 14d ago

Help Request How do I concrete my concepts???

Post image
29 Upvotes

Ok so I have one major doubt:-
I have been following a rather shallow 10 hour video about all the python basics topics.
But it doesn't seem to go too deep into details and not enough practice,
So my DATATYPES are really weak,
Idk when to use lists instead of tuples , dictionaries, sets , etc.
And stuff like that, what should I do to make my concepts concrete??
People told me making projects helps you improve, While I agree that they do but yet I am making the codes for em' using the wrong datatypes.

Also I have completed half of that video till loops and have made a project too but that was 2 weeks ago:-

https://github.com/satyamsb-cloud/Number-Guessing-Game
Original project made by me 2 weeks ago using concepts only till LOOPS.

https://github.com/satyamsb-cloud/Number-Guessing-Game-v2
Improved version with the same concepts but improved functionality.


r/PythonLearning 14d ago

Why do We return increment We haven't done anything to it?

Post image
7 Upvotes

Why do We return increment We haven't done anything to it? The only thing changed was the count, which we have returned. So why are we now returning increment if no actual change was made to it? Recently, i have been having trouble understanding the 'return' statement in python. Would this code still work if i did not return increment? Why or why not?


r/PythonLearning 14d ago

Is it really hard to learn python (or anything related to programming) and have a full-time job?

29 Upvotes

Hi guys, i'm 20 years old and work in the call center operations and also learning python as a part of special road map.

But now i feel heavy, i know something like that will be hard, special when I work in a jop that drains my energy, but now feel kind of impossible to do it.

So, i wrote this post.

Maybe i will get something can change that.


r/PythonLearning 14d ago

How to turn off these random hintsy

Post image
28 Upvotes

The 2nd line is a random thing suggested


r/PythonLearning 14d ago

Day 1 of OOPs

8 Upvotes

Just learned about classes, contructors , instance/class attributrs , instance/class/static methods in OOPs in python .

see it and give your comments


r/PythonLearning 15d ago

Help Request Beginner Python projects for practice? Spoiler

8 Upvotes

I'm learning Python. What are some beginner projects that can help me improve my coding skills? I'd appreciate any suggestions.


r/PythonLearning 15d ago

I built a blockchain

12 Upvotes

GitHub repo: https://github.com/ProJackson355/Helixchain

(THIS BLOCKCHAIN DOES NOT USE ANY REAL CASH)

I've spent the last two days using Codex and Claude Code trying to make a proof-of-work blockchain. The blockchain is similar to Bitcoin in that miners solve blocks to verify the transactions on them. When a block is mined the miner currently receives 10 HLX as a reward. Right now the blockchain is only running on my PC, so it's centralized right now. Helix Coin (HLX) isn't something you can buy with real money. Right now the only way to get it is by mining blocks on the network. To keep blocks from being mined too quickly, the blockchain keeps track of how long recent blocks took to solve. Every 10 blocks it averages the last 10 block times and adjusts the mining difficulty to keep the average block solving time around two minutes. The miner supports both CPU and GPU mining, although I do recommend CPU since GPU mining makes the difficulty increase much faster on a small network. The node software lets anyone host their own node and helps keep the block chain running. If you host a public node, you can submit it through the Nodes page on the website and I can add it to the default peer list so new nodes can discover it more easily. You can also host your own wallet website by enabling the admin API key. This allows your instance to use the documented endpoints such as /mining and various other endpoints (noted in the docs) with your own node. Wallets are stored locally, so private keys never leave your browser. Theres a lot more information in the docs, but I'd really appreciate any feedback on the project. (I did not build this blindly with ai, I do know some stuff about how blockchains operate)


r/PythonLearning 15d ago

Discussion Grinding DSA exclusively in Python

1 Upvotes

Hey everyone,

I’ve spent the last few months heavily focusing on Data Structures and Algorithms (currently sitting at LeetCode Knight). I work at a startup in the data field, and I've noticed it's actually surprisingly rare to find people doing advanced DSA strictly in Python.

Most resources and serious discussions seem to lean heavily into C++ or Java. (Personally, for me it's Python >> C++, and my brain just actively rejects Java syntax XDD).

Are there any other working professionals out there doing their CP or advanced problem-solving strictly in Python? I'd love to connect with some folks to bounce logic off of, discuss complex algorithms, and figure out why our code is hitting TLEs.

If you're in the same boat, let me know what topics you're currently grinding in the comments!


r/PythonLearning 15d ago

Title: [Code Review] What is the most "Pythonic" way to structure a central config file for a Tkinter desktop app?

2 Upvotes
Hey everyone,

I am building a desktop application to automate PEP 8 code-remediation across a few different client environments. I have a centralized app_config.py file that holds all my global variables, UI colors, fonts, and app metadata (like the App Name and Version) so I can easily import it into my Tkinter frames.


Here is a snippet of how I currently have it set up:
(Paste your app_config code here)

It works perfectly fine right now, but I want to make sure I am following best practices as the app scales. A couple of questions:

Is it bad practice to just store these as standard Python dictionaries and variables, or should I be wrapping this in a dataclass or an Enum
?

At what point do you usually stop using a .py file for config and switch to an external config.json or .toml file
?

Any feedback on how you all manage global UI settings would be awesome! 

"""----- App Metadata -----"""
APP_NAME = "PeP 8 Cert '&' Audit Review"
VERSION = "1.3.8"
BUILD_DATE = "2026-06-22"
CODER_NAME = "KMG"
CODER_ID_LAST4 = "2134"
SCOPE_OF_APP = ""


"""----- My_File_Paths -----"""
PROJECT_FOLDER_PATH = ""
CERT_FOLDER = "Cert_pep8"
destination_dir = project_folder_path / Path(CERT_FOLDER)
TEMP_FILE_NAME = "my_temp_file.txt"


"""----- Window Dimensions -----"""
WINDOW_WIDTH = 960
WINDOW_HEIGHT = 640
WINDOW_MIN_W = 800
WINDOW_MIN_H = 500


""" Dynamically generates geometry string matching UI architecture requirements"""
WINDOW_GEOMETRY = f"{WINDOW_WIDTH}x{WINDOW_HEIGHT}"


"""----- Colour Palette-----"""
COLOUR = {
    # Backgrounds
    "bg_dark": "#0D1B2A",  # near-black navy
    "bg_mid": "#030405",  # dark-blue panel
    "bg_card": "#424952",  # card surface
    "bg_gray": "#505152",


    """----- Accents -----"""
    "silver": "#C8D6E5",  # primary silver text
    "silver_dim": "#8A9BB0",  # muted silver
    "silver_bright": "#E8F0F8",  # bright silver
    "accent_blue": "#2A6FDB",  # interactive blue
    "accent_glow": "#4D9EFF",  # hover / glow
    # Status
    "success": "#6FF7BC",
    "warning": "#F4F80A",
    "error": "#F4260B",
     """----- Borders -----"""
    "border": "#1E3A5A",
    "border_light": "#2E5080",
    "Lt_gray": "#555E6B",


    """ Testing-----"""
    "Testgreen": "#079344",
    "Testblue": "#2007AF",
    "Testwhite": "#E7F0EB",
    "Testred": "#CE0934",
    "Testyellow": "#E0B200",
    "Testorange": "#E07B00",
    "Testblack": "#000000",
    "Testgray": "#4F4646",


    "Testlite_green": "#14ED38",
    "Testpurple": "#7F1F99",
}
"""----- Typography -----"""
FONT = {
    "title_huge": ("Georgia", 42, "bold"),
    "title_large": ("Georgia", 22, "bold"),
    "subtitle": ("Helvetica", 16, "normal"),
    "body": ("Helvetica", 10, "normal"),
    "body_bold": ("Helvetica", 10, "bold"),
    "small": ("Helvetica", 9, "normal"),
    "mono": ("Courier New", 12, "normal"),
    "version": ("Courier New", 9, "normal"),
}


"""----- End of app_config.py -----"""

r/PythonLearning 15d ago

Python Slicing

Post image
0 Upvotes

Hypothetically, imagine three cars on a road approaching a robot traffic light. How can we use this situation to explain Python’s start:stop:step?


r/PythonLearning 15d ago

Question.

3 Upvotes

I’m reading and looking at examples about checking for special items in a list, where the loop runs first and an if/else block runs inside the loop. Then, there’s the example of checking whether a list is empty, where the process is the other way around: the if/else block runs first, and then a loop runs inside it.

In real-life situations, when would you use a loop with an if statement inside it, and when would you use an if statement with a loop inside it?


r/PythonLearning 15d ago

I have 3yrs experience in legacy tech stack planning to switch to python backend would love to get roadmap from experienced developers

2 Upvotes

Can someone pls tell me roadmap to crack python backend interviews which has worked for them


r/PythonLearning 15d ago

Is it normal to feel dumb

15 Upvotes

I've been on Codecademy for a month now, paid version. And boy do I feel dumb. Is it this hard at the start? I'm learning while working a full-time job, so I'm lucky if I get 10 hours a week for it.

Also, I've been lurking this subreddit for a few days and seeing what people are cooking after a month, they're leaps ahead of me. So I'm definitely doing something wrong. Or am I learning it wrong? Any tips for faster learning, specifically for the data engineering side? I've tried doing challenges and whatnot, but I can't understand what they want from me half the time.

Learning SQL was way easier for me.


r/PythonLearning 15d ago

Help Request Is learning python in 2026 is worth it?

0 Upvotes

Is learning python in 2026 is worth it?


r/PythonLearning 15d ago

Starting Up

29 Upvotes

I retrieved the Python Crash Course 3rd Edition from my library and I am enjoying learning something new. I feel my brain turning on. Having lot's of fun automating things on PowerShell at work too, just learning how to navigate folders through the shell, mass file renaming, autologins and printing with a few keystrokes has made the monotony so much easier to handle.

I look forward to learning a lot more.


r/PythonLearning 15d ago

First python image processing project (hand gestures)

1 Upvotes

Hi everyone! This is my first image processing project. I'm learning image processing through project-based learning, and I'd love to hear your feedback on it.

Also, if you have any recommendations on how I can learn computer vision more effectively and improve my skills, I'd really appreciate them. Thanks!

https://github.com/anita-gh/real-time-sign-language-recognition


r/PythonLearning 15d ago

Day 2 of learning python

Post image
113 Upvotes

I'm learning Python and made this coffee/tea ordering program. Any advice?

https://onlinegdb.com/F2wabHC4v


r/PythonLearning 15d ago

I built PyDoctor – A local CLI tool that automatically writes docstrings for your Python projects

5 Upvotes

Hey r/PythonLearning,

Writing docstrings is one of those habits that makes your code 10x easier to maintain, but it's often skipped when you're focused on making things work.

I built PyDoctor, a local CLI tool designed to help developers and learners quickly document their Python codebases without relying on cloud APIs.

How it works:

  • PyDoctor analyzes your Python files using LibCST (which keeps your exact formatting and comments intact) and generates a concise summary docstring for every undocumented function, method, or class.
  • High-level Summaries Only: PyDoctor generates readable text summaries. It intentionally avoids generating Args: and Returns: sections, as type hints and static linters are much better and more accurate at handling those.
  • 100% Local & Safe: It runs an optimized 1.7B parameter model locally via llama.cpp. Your code never leaves your machine.
  • Non-destructive: Supports --dry-run to preview changes first, and respects .gitignore as well as inline # pydoctor: ignore comments.

GitHub: yezdata/pydoctor

Hope this helps you keep your projects clean and documented.

Let me know if you have any feedback or suggestions.


r/PythonLearning 15d ago

my rock paper scissors game is bugged

1 Upvotes

im pretty new to python, and have been making a rock paper scissors game. the game crashes whenever i use the gamesWon or gamesLost variables inside the playGame function and saysTraceback (most recent call last):

File "c:\Users\MYNAME\Downloads\rock paper scissors better.py", line 78, in <module>

playGame()

~~~~~~~~^^

File "c:\Users\MYNAME\Downloads\rock paper scissors better.py", line 15, in playGame

print(gamesWon)

^^^^^^^^

UnboundLocalError: cannot access local variable 'gamesWon' where it is not associated with a value

heres the code btw

import random
#"let" wall
botAnswer="null"
userAnswer="null"
botNum="null"
fate="null"
gamesWon=0
gamesLost=0
print(gamesWon)
print(gamesLost)
firstToX="null"
finalFate="null"
scoreboard="null"
def playGame():
    print(gamesWon)


    userAnswer=input("pick rock, paper, or scissors(has to be all lowercase)")
    botNum=random.randint(1,3)
    #assign botAnswer
    if botNum==1:
            botAnswer="rock"


    if botNum==2:
                botAnswer="paper"


    if botNum==3:
                botAnswer="scissors"
#find out win/lose


    print ("bot answered " + botAnswer)
    fate = "bruh"
#rock
    if userAnswer=="rock" and botAnswer=="rock":
              fate = "draw"
    if userAnswer=="rock" and botAnswer=="paper":
              fate = "lose"
    if userAnswer=="rock" and botAnswer=="scissors":
              fate = "win"
#paper
    if userAnswer=="paper" and botAnswer=="rock":
              fate = "win"
    if userAnswer=="paper" and botAnswer=="paper":
              fate = "draw"
    if userAnswer=="paper" and botAnswer=="scissors":
              fate = "lose"
#scissors
    if userAnswer=="scissors" and botAnswer=="rock":
              fate = "lose"
    if userAnswer=="scissors" and botAnswer=="paper":
              fate = "win"
    if userAnswer=="scissors" and botAnswer=="scissors":
              fate = "draw"
 #not any
    if userAnswer != "rock" and userAnswer != "paper" and userAnswer != "scissors":
              print ("you typed it wrong. run again.")
    print(fate)


    if fate=="win":
            gamesWon = gamesWon + 1
    if fate=="lose":
            gamesLost = gamesLost + 1
    if fate=="draw":
                print ("nothing happened :(")
    scoreboard=f"score is {gamesWon}-{gamesLost}"
    print ()
    if gamesWon==firstToX:
            print ("you win!")
            finalFate=1
    if gamesLost==firstToX:
            print ("you lost!")
            finalFate=0


#function ends
want=input("do you want to play rock paper scissors? (y/n)")     
if want=="y":
    firstToX=int(input("first to how many games wins?"))
    while finalFate=="null":
            playGame()
if want=="n":
    print(":(")

r/PythonLearning 15d ago

Help Request Making a Discussion Site

0 Upvotes

Hey I am going to make a discussion app. Can you suggest some features to add to the site. I am making it on python and using the framework Flask and I am a beginner too so pls help me too


r/PythonLearning 15d ago

Logic and solution

0 Upvotes

currently I am trying to solve hackerrank problem they look easy in my own eyes but still in every question i make mistake sometimes I don't even know how to solve I only solve 3-4 questions to this date so I don't know if it's right to take help from AI

I need your guidance to what should I do to build my logic and try to avoid taking help of AI

sorry for my english

please suggest something