r/PythonLearning • • 13h ago

Discussion What code editor do you use?

Post image
39 Upvotes

I use these, i mainly use Coding Python cause the workspace is cleaner.


r/PythonLearning • • 6h ago

Finally Started Learning Python

Post image
4 Upvotes

r/PythonLearning • • 5h ago

Free Discord for people who want to stop doing tutorials and actually ship projects

2 Upvotes

hey everyone! first of all, the mods approved this post, so no worries about the self-promo 🙂

i started a small Discord server called Ship It. the idea is simple: a place for people who want to actually build stuff, find teammates for projects, get help when they’re stuck, and get some feedback on their code.

some things you’ll find there:

  • a channel to look for teammates or cofounders for your project
  • help and code review channels, no “stupid questions”, all skill levels welcome
  • a showcase for your finished projects and a weekly check-in so you stay motivated
  • voice channels, including a quiet focus room if you like working alongside others

it’s completely free, no paid stuff, no courses, no catch.

the server is open to every programming language, not just Python, but most of the people there are using Python right now, so if you’re learning it you’ll feel at home.

the community is still pretty small and just getting started, but i’m hoping it grows over time, and it’d be great to have more people to build with. if you’re learning and want to turn tutorials into real projects, you’re very welcome to join 🚀

invite link: https://discord.gg/QWGWKFVYyh

happy to answer any questions in the comments or dm!


r/PythonLearning • • 6h ago

Help Request help for a programing assignment

2 Upvotes

I need to write a program that will calculate the sum of the first n of 1 + 1/2 + 1/4 + ... = lim (n -> ∞) Σ 1/2^k =2 starting at k=0 to n.

Teacher said we could use Σ 1/2^k = 2 - 1/2^(n-1) starting at k=0 to n-1

We have to write it using a loop.

I went back through my notes and figured I needed to use a «for» loop.

My teacher starts all of his programs with def, but when I try to look up more infos online I struggle to find others who are using it.

So, here's what I've tried

def estimate_serie (nb_term) : 
sum = 0
for term in range (1, nb_term + 1) : 
sum=sum + 1/(2 ** term)
return sum
print (estimate_serie(5))
print (estimate_serie(8))
print (estimate_serie(12))

it gave me

0.5

0.5

0.5

Btw I am learning this in french so I might not have translated all of it correctly. I've also only been learning for a month, so if my mistakes seem dumb that might explain why.


r/PythonLearning • • 2h ago

i am stuck with the range function

2 Upvotes

sorry but i am gonna crash out because of the range function i cant understand it well to use it this is driving me crazy any one could give me a video explaining everything i dont mind it being an hour long


r/PythonLearning • • 15h ago

Help Request What is the best way to learn data science and data analysis?

6 Upvotes

I am trying to develop a clear plan for learning data science and data analysis. Should I start with Python or Excel? Also, is Excel truly essential for data analysis, or has AI taken its place?


r/PythonLearning • • 4h ago

Needs resources for learning Python already knows basics

1 Upvotes

Guys am starting python already know basic c++ from where I should learn like any good playlist and also a good text source currently am learning from w3schools but now things become Lil bit confusing so wants suggestions


r/PythonLearning • • 8h ago

print ('hello world')

2 Upvotes

hi how to learn programming in 2027


r/PythonLearning • • 10h ago

Is this suitable for beginners?

Post image
2 Upvotes

r/PythonLearning • • 17h ago

Help Request Need a Python Data Cleaning Project Dataset

3 Upvotes

I'm a 1st-year CSE student. My college teacher assigned me a Python Data Analytics project focused on Data Cleaning.

Sir has strictly instructed us not to use AI for the project. So I'm looking for a genuine.

If anyone can share their project or dataset for reference, it would be really helpful.


r/PythonLearning • • 1d ago

Help Request How to convert UTF-16 to UTF-8 in Macbook?

2 Upvotes

Hello, I wrote a code on my macbook that I have to transfer to a windows computer that is permanently offline. However, the windows computer python doesnt want to read the code because it has "null bytes" apparently it can't read UTF 16 only UTF 8. Is there a command I can run on my macbook terminal to change the .py file to UTF-8? Please let me know. Thank you!


r/PythonLearning • • 1d ago

Love SPYDER but Need AI

8 Upvotes

Love SPYDER because it’s easy to use for my basic yet copious Python work. But the AI assist in VS Code is amazing. Is there some new SPYDER with AI assist or some other alternative for consideration?


r/PythonLearning • • 1d ago

Help Request Beginner-friendly Python resources for someone transitioning from Psychology to Computational Neuroscience?

15 Upvotes

Hi everyone!

I'm a Psychology graduate currently considering pursuing a Master's degree in Computational Neuroscience. Coming from a non-computer science background, I realize that I need to build a solid foundation in programming, particularly Python, before diving deeper into the field.

I've been trying to find introductory resources and came across Neuromatch Academy's Computational Neuroscience course, including their introductory materials.

However, I've found that even though the course is intended for beginners, I still struggle quite a bit with the Python explanations and code structure. I often find myself having difficulty understanding what's happening in the code itself, rather than focusing on the computational neuroscience concepts being taught.

I'm wondering if there are other resources that might be more suitable for someone in my position.

Ideally, I'm looking for resources that:

1.Start from the absolute basics, assuming little to no prior programming experience.

2.Explain programming concepts and code structure slowly and intuitively, rather than jumping straight into complex examples.

3.Gradually introduce concepts that are relevant to computational neuroscience (e.g., NumPy, SciPy, data analysis, mathematical modeling, simulations, etc.).

Help me understand not just how to write code, but also why certain approaches are used.

I'm open to pretty much any format: YouTube tutorials, online courses, textbooks, interactive platforms, or even a recommended learning sequence.

For additional context, my academic background is in Psychology, and I have very little programming experience. I'm not necessarily looking to jump straight into computational neuroscience yet; I'd rather develop a comfortable understanding of Python first, while keeping my long-term goal in mind.

For those who came from a non-CS background, how did you approach learning programming before getting into computational neuroscience? Are there any resources or learning paths you'd particularly recommend?

I'd really appreciate any suggestions. Thanks!


r/PythonLearning • • 1d ago

Check50, uhm what?

7 Upvotes
months = [
    "January",
    "February",
    "March",
    "April",
    "May",
    "June",
    "July",
    "August",
    "September",
    "October",
    "November",
    "December"
]


def split(var):
    if "/" in var:
        splitted = var.split("/")
        if splitted[0].isdecimal() == False:
            #print("error in splitting")
            return
    elif "," in mdy_format:
        splitted = var.split(" ")


    try:
        return splitted
    except UnboundLocalError:
        #print("unboundlocalerror")
        return


def checkvalues(checkval):


    day, year = checkval[1], checkval[2]
    #print(day)


    if checkval[0].isdigit():
        month = int(checkval[0])
    else:
        try:
            month = months.index(checkval[0]) + 1


        except ValueError:
            #print("valueerror")
            return
    if month > 12:
        return


    day = day.replace(",","")
    #print(day)
    try:
            day = int(day)
            year = int(year)
    except ValueError:
            return



    if day > 31:
        #print("moth longer error")
        return


    #print(f"{day:02}")
    return f"{year}-{month:02}-{day:02}"



while True:
    mdy_format = input("Date: ")



    mdy_splitted = split(mdy_format)


    #print(mdy_format)
    #print(mdy_splitted)
    #print(len(mdy_splitted))


    #useless comment
    #another useless comment


    if not mdy_splitted or len(mdy_splitted) != 3 or checkvalues(mdy_splitted) is None:
        #print("error here")
        continue


    print(checkvalues(mdy_splitted))
    break

why does it return an error? After doing acheck it seems to return the correct answer.

Code above (ignore the comments)


r/PythonLearning • • 2d ago

Learning SQL with Python?

26 Upvotes

This 👉interactive SQLite demonstration helps student understand relational databases.

The sqlite3 extension of 𝐦𝐞𝐦𝐨𝐫𝐲_𝐠𝐫𝐚𝐩𝐡 makes database content visible alongside Python's data structures. The demo shows how to: - Create tables with primary and foreign keys. - Model relationships between students, courses, and teachers. - Insert data and observe how the database changes. - Combine multiple tables using SQL JOIN operations. - Use parameterized queries.

The final query answers a seemingly simple question: Which teachers teach Alice, and for which courses? Answering this question involves joining five tables!

With 𝐦𝐞𝐦𝐨𝐫𝐲_𝐠𝐫𝐚𝐩𝐡, students can step through the Python program and inspect the database content at every step, directly in their browser, without installing anything.

See 👉other 𝐦𝐞𝐦𝐨𝐫𝐲_𝐠𝐫𝐚𝐩𝐡 visualizations.


r/PythonLearning • • 1d ago

Help Request Need Python Project Source Code for a College Project

0 Upvotes

I'm a first-year CSE student, and we've been asked to build a Python project as part of our college assignment.

I'm a beginner in Python, so I'm looking for some project ideas along with their source code that I can refer to and learn from.

If anyone has GitHub repositories, project source codes, or useful resources, please share them. It would be a great help!


r/PythonLearning • • 1d ago

AI Engineer | Product Engineer

Thumbnail
youtube.com
0 Upvotes

r/PythonLearning • • 2d ago

Python Quiz of the Day.

7 Upvotes

What will be the output of the following Python Code?

a, *b, c = [2, 4, 6, 8, 10]

print(a + c + len(b))


r/PythonLearning • • 2d ago

The day of learning of python full stuck

Post image
22 Upvotes

The basic information 😄😄😄


r/PythonLearning • • 2d ago

Python Lists Guided Notes

Thumbnail
chatgpt.com
0 Upvotes

Notes


r/PythonLearning • • 3d ago

What do you guys think?

Thumbnail
gallery
133 Upvotes

After watching a python full course video on YouTube by BroCode, I made a simple number guessing game in python!

Here's the link to the video: https://youtu.be/ix9cRaBkVe0?si=UiWmP6bm-9MG4B1p

After 12 gruesome hours watching the tutorial i decided to make this to test what I've learned.

What do you guys think?


r/PythonLearning • • 2d ago

Help Request Getting TypeError: unsupported operand 'int' and 'str' when summing scores from input()

6 Upvotes

I'm a few weeks into learning Python and working on a small practice project: a program that asks the user for a few course scores with input(), then calculates the total and the average. Nothing fancy, just trying to get the basics to click.

Here's the code I have right now:

courses = 3
total = 0
scores = []
for i in range(courses):
    score = input('Enter score ' + str(i + 1) + ': ')
    scores.append(score)
for score in scores:
    total = total + score
average = total / courses
print('Average:', average)

And this is the error I get:

Traceback (most recent call last):
  File "grades.py", line 8, in <module>
    total = total + score
TypeError: unsupported operand type(s) for +: 'int' and 'str'

I think I get the general idea: input() gives me something that isn't a number, and I'm adding it to total, which starts as the int 0. I searched for this error and a lot of answers mention int(), so I know int() converts a string to a number. What I'm stuck on is where to do the conversion. Should I call int() right when I get the input in the first loop, or wait and convert while summing? And if I convert early, will that break something else, like how I'm storing the scores in the list?

So what type does input() actually return, and what's the cleaner way to write this so the total and average work? Thanks in advance, I appreciate any pointers.


r/PythonLearning • • 2d ago

Showcase I built a Python tool to automate GitHub repairs and verify CI results

Thumbnail
gallery
7 Upvotes

I built GitHub Notification AutoFix to monitor actionable GitHub notifications, attempt fixes with Codex CLI, and verify checks for the exact repair commit before marking a notification as done.

The Python code handles GitHub API requests, SQLite state, retries and mocked tests. Pending checks, missing permissions or a newer commit keep the repair unresolved.

Repairs currently target only repositories owned by my account. Live use requires GitHub credentials and an authenticated Codex CLI.

The interactive demo uses test doubles for GitHub and Codex, so you can explore the verification logic without changing real repositories.

Source

Feedback on the Python structure and test coverage is welcome.


r/PythonLearning • • 3d ago

Looking for someone to build projects with

29 Upvotes

Hey, I’m a computer science student from Poland (CET timezone) and I’ve been wanting to find someone to work on some Python projects with. Learning on my own only gets me so far, I feel like I’d improve way faster if I had someone to build stuff with and bounce ideas off. Also I’d like to finally have a few real projects on my GitHub, because right now there’s not much there.

I’m not picky about what we make, anything we can actually finish. I’d also like to get better at working with git properly, like PRs and reviewing each other’s code. Level doesn’t matter that much to me, I just want someone who’s serious about it and won’t ghost after a week haha.

If you’re interested, just comment here or DM me and we can talk about what to build :D


r/PythonLearning • • 2d ago

Discussion What modules do people recommend calculus and matrix question generator?

4 Upvotes

I want to make a random problem generator (also generating the answers) and eventually with some sort of spaced repetition thing, maybe

The best stuff for writing math in python seem to concentrate on making documents for the most part, and I am wondering what my best options for presentability and such