r/learnprogramming • • Mar 26 '17

New? READ ME FIRST!

830 Upvotes

Welcome to /r/learnprogramming!

Quick start:

  1. New to programming? Not sure how to start learning? See FAQ - Getting started.
  2. Have a question? Our FAQ covers many common questions; check that first. Also try searching old posts, either via google or via reddit's search.
  3. Your question isn't answered in the FAQ? Please read the following:

Getting debugging help

If your question is about code, make sure it's specific and provides all information up-front. Here's a checklist of what to include:

  1. A concise but descriptive title.
  2. A good description of the problem.
  3. A minimal, easily runnable, and well-formatted program that demonstrates your problem.
  4. The output you expected and what you got instead. If you got an error, include the full error message.

Do your best to solve your problem before posting. The quality of the answers will be proportional to the amount of effort you put into your post. Note that title-only posts are automatically removed.

Also see our full posting guidelines and the subreddit rules. After you post a question, DO NOT delete it!

Asking conceptual questions

Asking conceptual questions is ok, but please check our FAQ and search older posts first.

If you plan on asking a question similar to one in the FAQ, explain what exactly the FAQ didn't address and clarify what you're looking for instead. See our full guidelines on asking conceptual questions for more details.

Subreddit rules

Please read our rules and other policies before posting. If you see somebody breaking a rule, report it! Reports and PMs to the mod team are the quickest ways to bring issues to our attention.


r/learnprogramming • • 5d ago

What have you been working on recently? [October 17, 2026]

13 Upvotes

What have you been working on recently? Feel free to share updates on projects you're working on, brag about any major milestones you've hit, grouse about a challenge you've ran into recently... Any sort of "progress report" is fair game!

A few requests:

  1. If possible, include a link to your source code when sharing a project update. That way, others can learn from your work!

  2. If you've shared something, try commenting on at least one other update -- ask a question, give feedback, compliment something cool... We encourage discussion!

  3. If you don't consider yourself to be a beginner, include about how many years of experience you have.

This thread will remained stickied over the weekend. Link to past threads here.


r/learnprogramming • • 14h ago

Ashamed of using AI

70 Upvotes

Hey everyone, long time programmer here (14+ years)

I realized that AI fucked with my enjoyment of coding when it first released, and noticed myself getting more and more dumb (Literally couldn't think where to start on projects), and that made me depressed.

I ended up straight up going zero AI, and I have been loving it (Highly suggest everyone to question how much they rely on it).

Back to the topic.

I started learning Lua, and find it tricky to understand tables coming from C#, but I'm getting there.

I find that when I'm stuck between 2 or more design choices, and for the life of me can't decide, I ask AI, telling it to not just tell me I am right if I'm wrong, but actually give me good advice, and using AI also helps me ask a question on if my understanding of something is correct.

The main thing, I feel so ashamed of using AI for what I just listed above, but I know 1 person who does programming, the guy who helped me learn, and he stopped a long time ago with Programming, and yes, sometimes I ask him but it takes days getting a reply when I ask, so I find myself locked into asking AI for advice.

My main point of this is basically, why do I feel literally depressed sometimes just because I ask for input on my design choices and if I am understanding something correctly?


r/learnprogramming • • 24m ago

Resource Brand new to frontend and backend development

• Upvotes

Hi,

I am brand new to frontend/backend development. I have been working for 20 years but I want to learn a new skill because I don't know how to secure my next 20 years in employment. I know web development is a dying skill with AI, but if I don't understand the basics, I won't be able to progress.

I work well with books. Yes, I grew up with them. I am looking for books to teach me HTML, CSS, Java and then for the backend either Java or Python. Could you please suggest accessible books for me?

I can follow process maps and self-teaching well. I have access at work for tutorials but they are 50 hours long and barely scratch the surface. They were made by busybodies who wanted a promotion and luxuriate in the sound of their own voice. I tried tutoring, but the tutors have no structure.

My family and full-time commitments do not leave me time to go to a class. Any suggestions would be very appreciated


r/learnprogramming • • 12h ago

What are interesting Programming fields that is worth trying?

14 Upvotes

I am IT student but interested more in coding and programming stuff rather than hardware and started with web dev but ended soon because it wasn't fun enough, then started java and spring boot but that wasn't that much fun because everything seems to be confused and I don't know what's going on and then tried some modding started with minecraft but immediately quit (IDK Why) now I am thinking about to start with game dev to try to make tiny 2d game in java. but still I wanna hear from you guys.. Which Programming fields you found out more interesting and worth trying as beginner


r/learnprogramming • • 6h ago

why is this returning read only once i get to the enter name stage

2 Upvotes

import java.util.Scanner;

public class main

{

public static void main(String[] args) {

Scanner kboard = new Scanner(System.in);

System.out.println("Press 1 to enter lottery numbers or 2 to enter name: ");

if (kboard.nextInt() == 1) {

System.out.println("Enter your lottery numbers");

int lotteryNumbers = kboard.nextInt();

} else {

System.out.println("Please enter your name: ");

String name = kboard.nextLine();

}

}}


r/learnprogramming • • 9h ago

question in threads

3 Upvotes

In a single-core system, what happens if two threads from different processes access the same physical memory address?

The official answer says:

Neither program crashes, and both produce expected results.

I don't understand why that must be true.

A memory access could be a write, not just a read. For example, couldn't Thread A read/write that address, then get context-switched out, and Thread B access the same physical address before Thread A finishes its operation?

Wouldn't that potentially cause a race condition or unexpected result, even on a single core?

Am I missing an assumption in the question?


r/learnprogramming • • 1d ago

Topic For a mathematician: What’s the actual difference between languages

157 Upvotes

I always read stuff like „python is easier“ or „C++“ is more performative… and I have absolutely no idea what that is supposed to mean

For me (an arrogant mathematician) programming is just simple logic plus syntax. Everything comes down to definitions, calculations, saving values for variables and „If“. Most other syntax is just another way of writing those definitions, calculations, saving values for variables and „If“.

So, what’s the fuzz about? What‘s the difference? That language A uses another form of brackets? Or language B specifically needs something to be manually defined whereas language C just assumes standard definitions?

What am I missing? For me, learning syntax is the most dull aspect of programming.


r/learnprogramming • • 11h ago

Tutorial Should I start Coding With CS50X and CS50P

3 Upvotes

Hello, I just want to start coding to teach ai and make my own. I know algorithms and stuff, but I never disciplined myself to do it for weeks, months. I think I will learn Python, and I think to start with Harvard’s CS50X and then CS50P im not sure if I should watch CS50AI because focusing on one source is bad, as I have been told. What are your recommendations?


r/learnprogramming • • 23h ago

Topic Python experts, how did you not give up on Python beginner projects?

20 Upvotes

Hi everyone. I've been learning python fundamentals for the last few months, that is , variable to OOP. I can work with python really well on individual concepts, for instance any exercise that just requires OOP I can comfortably do it. So earlier this month I started working on python beginner projects to try and combine all those concepts. The first two projects(expense tracker, word guessing game) I worked on were okay and I was able to complete them in two days, but for my third project, a library management system, I've been at it for over two weeks, and I'm still stuck on the same problem. I tried researching and I still can't figure it out, cause there is always an error to fix. I feel so tired and burnout, which got me wondering, to all the python experts in this community, did you go through this phase or I'm I a little bit dumb. Also how did you not give up on programming and how did you start your begginer projects.


r/learnprogramming • • 12h ago

Resource Resources to learn Web Dev from other than TOP..

2 Upvotes

I am in class 9 and wanna learn web dev but dont know what free course i should choose. Earlier I chose TOP but i have to install VM for that and my father is denying to do so cuz its his laptop... Please help me out... and make sure that the course you tell should be documented


r/learnprogramming • • 11h ago

what should i choose

1 Upvotes

i am learning computer science at school and wanna make some projects at home. i am currently learning java and decided to download visual studio code instead of using the online compilers like we do at school for some reason, and the installer asks me if i want to install github copilot CLI and i dont know what it is. should i install it or nah?


r/learnprogramming • • 11h ago

Looking for projects in Machine Learning (ML), Image Processing, and Deep Learning. I’m eager to contribute and collaborate!

1 Upvotes

Hi everyone,

I am a Master's student specializing in Machine Learning, Artificial Intelligence, and Image Processing. I am looking for projects to contribute to and would be happy to collaborate with anyone who has project ideas in these fields.

Thank you!


r/learnprogramming • • 13h ago

Are shorter but more confusing solutions better on coding sites?

0 Upvotes

I've been practicing python on codewars.com, and this is listed as the best practice:

def alphabet_position(text):
    return ' '.join(str(ord(c) - 96) for c in text.lower() if c.isalpha())

while my code is longer, but I feel is easier to read. Which one is better?

import string

def alphabet_position(text):

    output = ""
    for char in text:
        if char.isalpha():
            output += str(string.ascii_lowercase.index(char.lower()) + 1)
            output += " "

    return output.strip()

r/learnprogramming • • 17h ago

What to learn next? (If anything)

2 Upvotes

Background:
- From the U.K.
- Did an MSci in Maths and Statistics.
- Got a grad job at a Big 4 accounting firm and qualified as an accountant.
- Jumped over to being an analytics engineer instead, which has slowly shifted into being more of a data engineering / data platform engineering role.

Lots of SQL, Python (actual OOP not just scripting), some React (just so I could actually plug my stuff in).

Not sure where I go from here tbh. Used to be an AI sceptic but obviously I no longer am.

Do I want to remain a tech person with a background in accounting (in which case, what else do I learn?), or is the safer bet to be an accounting person with a background in tech?


r/learnprogramming • • 1d ago

Developing peripheral software for macOS

6 Upvotes

Hi,

I plan to develop peripheral software to change input mapping, assign some macros to keys on my keyboard for macOS for a learning purpose.

I do have working code for Windows written in C++. But I can't tell that I don't have a lot of experience with Objective-C.

The questions:

  1. Should I go with Swift or with Objective-C? I know that Objective-C combines with C++ without any problems, but I wonder, if this is a good idea to pick outdated language to develop software that I hope I will constantly maintain and improve?
  2. Can you recommend some books to developer such things for macOS?

Thanks


r/learnprogramming • • 1d ago

Help how to learn to code in this age of ai

18 Upvotes

Guys I am in college and I am doing dsa and web development but Idk how to study devlopment in what way should I do it .. especially frontend . It feels wasteful to study it and write code . Plus i feel like I am struck in tutorial hell I can't think of new things . Anybody help me out how should I do the coding idk I am just watching the video I am learning from and writing the code he is doing it feels like I am just copy pasting not learning anything at all . Help me out plus also tell me how should I adapt and what things to focus to be able to get a job atleast -_-


r/learnprogramming • • 1d ago

I'm 30 and enrolling on a boot camp coding course.

283 Upvotes

Can you guys list out, what's best for starting for a zero experience programming? I came from flying small airplane to decided change in career path. (Lost passion)

Like basics, YouTube, Jargons, Vocabulary. Just to give me a heads-up on what lies ahead.

I thank you all in advance.


r/learnprogramming • • 17h ago

Wanna make a music app

0 Upvotes

I've been wanting to make a music player for a while now and trying to decide on the right language for it. My plan in the end is to make my own server like Jellyfin or Navidrome (I don't use those because they don't fit my particular taste and my own pride). But I realize I do first need a working application that runs alone. I'm gonna run these on windows and android and want to try make for both before branching out into Linux and Mac. So yeah. I just need to know what language I need to learn first

EDIT: I already know python if that's helpful


r/learnprogramming • • 1d ago

Any advise whether I should shift courses (again)?

6 Upvotes

Greetings, I am currently a second year CS college student (first semester) while also taking leftover first year CS major subjects but since the job market, especially in tech (mostly because of AI), doesn't seem to be getting any better, I've been thinking of shifting back to my original course for the next semester, which is Psychology (second year, first semester before I shifted to CS) and pick up from where I left.

I shifted to CS because I've always been fascinated by Cybersecurity, programming, Linux, troubleshooting, creating things with code, etc. Plus, my uncle also told me to go for it because he said the demand is high and he knows someone from a company in Japan that's looking for IT grads.

The thing is... I'm fine with either but I really enjoyed CS.

CS is fun and I found it enjoyable since it drives me to focus and actually learn from the challenges presented to me. For Psych, I like learning about human behavior (predicting how they behave/act, how mental illnesses affects one, etc.).

I've heard that it is mostly AI-resistant since you need actual understanding of the human mind, emotions and the fact that some people would prefer talking to actual therapists, psychologists, etc. than machines/AI pretending to have emotions/feelings.

I'm aware that both fields are competitive but I'm worried about choosing the wrong path in the end and not having a stable job. I know everything may change... or not but I don't want to regret it and waste more years studying.

TLDR; I'm conflicted between continuing my CS course (2nd year, 1st sem with 1st year leftover majors) and shifting back to my Psych course (2nd year, 1st sem) due to the current unpredictable job market and possible unstable job in the future. I like both fields (leaning towards CS) but I don't want to waste more years studying just to spend a very long time looking for jobs for my chosen field.

I'm not sure if it would get any better or not in the future for tech students.


r/learnprogramming • • 1d ago

can you get an executable in python without using third part libraries?

1 Upvotes

In c++ I have object files but can I get an executable in python?


r/learnprogramming • • 1d ago

Want To learn Coding

3 Upvotes

hello guys i know the basics on how to code but is there anywhere i can get code for older smaller dos games or other small games

i am learning how to code and want to try port some games

thanks


r/learnprogramming • • 1d ago

Spaghetti Code vs Code Soup

14 Upvotes

I’ve heard of people referring to bad code in one of two ways:

  1. As spaghetti (“Bro look at this ungodly bad spaghetti code”)
  2. As soup (“Every single time someone uses feature X in their code, the codebase always turns into soup”)

Personally, I use them interchangeably. But since they are 2 different terms, they probably have different meanings, right?


r/learnprogramming • • 1d ago

How to make most of degree?

3 Upvotes

I'm starting to realize how much I'm not going to get anything out of learning a degree.

The issue that I'm having with this is, I learn with lot of trial and error but I can't make up time for this because I then have the assignments, coursework and things like that and in that process I just forget that I actually have to build a skillset.

For me, I feel like I want to learn to write good code but I can't know whether I'm writing good because I don't know what to compare it and don't know how to review my work.

How do you go about reviewing code?


r/learnprogramming • • 1d ago

Tutorial hello i was thinking about getting into cypersecurity from where should is start? and other things

1 Upvotes

its my first time ever to learn coding and i would know Your experience and what should i learn before i roll in Cybersecuritg and the types of it i want help to get start with it and the best open sources on internt?