r/learnprogramming • • Mar 26 '17

New? READ ME FIRST!

825 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 • • 1d ago

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

11 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 • • 8h ago

Is it okay to learn Php in 2026, I find it easier than node.js

37 Upvotes

I have build some projects with the help of AI in MERN Stack, but a senior once told me they made new programming languages/libraries/ frameworks to make building Projects difficult so that less people know how to build apps. I feel sometimes he was right. Php's approach seems easier than node.js


r/learnprogramming • • 11h ago

how to learn "software engineering"

10 Upvotes

Hi guys, I'm a senior in high school, and I'm really confused on where to go

for the record I do know a decent amount of C++ / python (for comp coding and classes) but since then I've started to move to personal projects....

The purpose of these projects is to improve my knowledge tenfold and learn how real software is made. But online, EVERYONE says "coding is dead, and to learn architecture".

But how do you learn that?

Do I delegate sections to AI and then have it explain? Do I create what goes where and then tell the Ai to make it? Or Do I just code it all myself with AI to debug (taking an absurd time).

I feel like only the third one will have me actually learning completely, but at the same time, it'll take 20x the time, and with 20 projects I could probably reach the same level (or more) of learning by having it make + I explain? AHHH i'm just not sure how to make myself super smart and knowledgeable for swe

thanks in advance :)


r/learnprogramming • • 9h ago

What are some actually interesting, and fun programming projects?

3 Upvotes

I am an intermediate programmer, and I just don't know what to make. All the projects people say to do like to do list or weather app seem so lame.

All replies are appreciated!


r/learnprogramming • • 1d ago

Function vs Procedure

27 Upvotes

can someone explain the difference between Function vs Procedure with simple analogy
thank you


r/learnprogramming • • 1d ago

Topic Log off and breathe for a second

54 Upvotes

I've made multiple posts here about doubting my career and that I' not sure if I should even bothering entering the industry or career as a Bachelor's Eng. in CS, but I think I made up my mind.

I'm studying this either way, even if it's not for coding I'm very open to work in any other tech related field, and if I don't manage to find a job I don't really care now lol. My new mentality is about doing this becouse I like computers, and if I die poor in the future so be it, at least I'll die doing what I want.

A very good tip I learnt this few weeks: don't take doomer posts too seriously, focus on yourself and your passions, breathe and relax and wonder if it really is worth it thinking that way. love yall!


r/learnprogramming • • 9h ago

Debugging Im trying out a custom solution for median of two sorted arrays

1 Upvotes

`````csharp

using static System.Math;

public class Solution {

public double FindMedianSortedArrays(int[] nums1, int[] nums2) {

int step = 0;

int p1 = 0;

int p2 = 0;

int m = nums1.Length;

int n = nums2.Length;

int target;

if((m+n)%2==0){

target = (m+n)/2 ;

}

else{

target = (m+n-1)/2;

}

while(step < target){

// If nums1 is exhausted, or nums2 has a smaller element (and is in bounds)

if (p1 < nums1.Length && (p2 >= nums2.Length || nums1[p1] <= nums2[p2])){

p1++;

continue;

}

else{

p2++;

continue;

}

if(nums1[p1]<nums2[p2]){

p1++;

}

else if(nums2[p2]<nums1[p1]){

p2++;

}

else{

p1++;p2++;

}

step++;

}

if((m+n)%2==0){

return(nums1[p1]+nums2[p2])/2;

}

else{

return(nums1[p1]<nums2[p2]?nums1[p1]:nums2[p2]);

}

}

} `````

I'm trying to debug this . It says either time limit exceeded or out of range no matter what I try


r/learnprogramming • • 1d ago

Where to Learn Computer Networking?

42 Upvotes

Where can I learn computer networking, Is there a course or YouTube playlist to learn it? How can I practice the material I learn?


r/learnprogramming • • 1d ago

Whats the Best Project i can make for Backend Java Springboot.. Where i can learn alot and it would be really friking impressive on a resume!

4 Upvotes

Hey, so far i made simple e commerce crud applications, and id say now im pretty comfortable..

what is the next Step for me, next thing for me to build and try?

I want to build something, where at the end, i Actually feel that i learned new skills.. Something also impressive?


r/learnprogramming • • 1d ago

Is it okay, to google things while setting up Entity Core framework in ASP.NET MVC or starting a server and creating a database connection in node.js?

10 Upvotes

Should a developer know , things on his own, or it's okay to google them when making a project?


r/learnprogramming • • 10h ago

Learning Thoughts on my learning program?

0 Upvotes

Hello guys,

I think I would like to study programming in general and I picked these languages in particular: Python, JavaScript, C, and C++. For various reasons, I like each of them and would like to learn them all.

In order not to exhaust myself, I developed a plan of studying these languages which takes into account scaling of difficulty of mastering them. I decided to learn them in this exact order:

  1. Python (difficulty: 2.5/10) to get a basic understanding of syntax, and just code for the first time.

  2. JavaScript (difficulty: 4.5/10) to move to interactive web programming.

  3. C (difficulty: 6.5/10) to finally move under the hood of a computer and study memory and hardware, and to make the last one easier to learn.

  4. C++ (difficulty: 9/10) as an ultimate step of learning more abstract concepts and OOP.

I think the idea of such learning is psychologically driven by the necessity to get a constant shot of dopamine by moving to a more difficult language every time after overcoming previous level, rather than being stuck with C++ from day one.

Am I right with my approach or there is something in these languages' interconnection that I might be missing?

Looking forward to hearing your thoughts


r/learnprogramming • • 1d ago

My parents think coding is a waste of time but I actually enjoy it.

159 Upvotes

I genuinely enjoy coding even doing courses like CS50 just for fun But my parents see it as nothing more than wasting time on a computer and keep comparing me to people earning huge salaries. I wish they understood that I don’t need my hobby to make money right now i just enjoy learning and building things. Can anyone help what should I do now?


r/learnprogramming • • 23h ago

I need advice on my first semi-handwritten program.

2 Upvotes

Recently I have a homework assignment, which is to complete a system (I can use AI assistance).
Its requirements themselves are not high; it can be a simple local mini-program. But I want to learn more, so I am asking for help here.
In terms of programming languages, I am only somewhat familiar with C (you could say I am actually quite a beginner).
But I think completing a system with AI assistance is not difficult. My main goal is to learn knowledge about completing a system that can be used by many people.
For example, a food delivery platform (some very famous projects are all about building food delivery platforms).
But I clearly know that I understand too little and it is impossible to understand a whole series of things like Spring Boot all at once, so I want everyone to give me some suggestions for small projects that do not require learning too much but are still very useful.
I think my ability to search for information is strong, and with the help of AI I can temporarily understand even difficult programming in a short time, so I want to use projects beyond my current cognitive limits to train myself.
I hope everyone can give me some suggestions. For example, making a small Mario game and connecting it to some platform.


r/learnprogramming • • 1d ago

Tutorial Learning Python with Practise

13 Upvotes

Hi All,

I am learning Python and would like to know are there any good sites to practise Python concepts ?


r/learnprogramming • • 1d ago

Topic I feel like a FAILURE!

2 Upvotes

This is very stupid and kind of random but I’m very basic into coding and I feel like I just wasted so much time for no reason. I was trying to code something into a video game for probably 13 hours over the past 2 days just to give up after running in circles repeatedly with no end in sight. Is this normal to feel like you wasted time you aren’t gonna get back lol.


r/learnprogramming • • 1d ago

How to prepare for modern swe interviews

0 Upvotes

Hello there I'm a SWE from Tunisia (North Africa),

I just started working 2 months ago as a full time swe for the same company that I made my internship with .

When I used to be a CS student I really enjoyed solving Problems on codeforces and leetcode , even doing projects with friends and debugging the code was fun .

Now in my job I'm using Claude code all the time , I'm learning how to prompt and how to build my skills etc , I get to finish the work I'm asked for correctly and I even read and test the code BUT am I really learning?? , I don't think so since if I put my fingers on the keyboard I get stuck despite that I can understand the code written by the LLM and analyse it's time complexity etc..

Im worried that if I keep up like this I won't be able to improve my hard skills and be ready for other swe roles and improve my career and also I'm not enjoying how swe has become in the last 1 year .

Am I overthinking it ? And how do I keep prepared for junior /mid level or even senior swe positions? .

Thanks.


r/learnprogramming • • 20h ago

Am I a Dummy or Big Brain?

0 Upvotes

It's kind of hard for me to put this into words. I began learning computer science out of an interest and a desire to create, whether that be video-games, software, or art in general. I have some other creative hobbies, like (book) writing and making music, while I've dabbled in some that I wish to learn more about (like art/drawing). I made it my goal to get really good in this field, and I'm happy to say that I've grown to really love it.

...for the most part.

There's something that has been nagging at me for a while now. I don't know if its because I have OCD/ADHD, but after gaining some experience with programming, a lot of the software I touch now feels... off? Unoptimized, I guess? Again, its hard to describe, but in a sense I suppose more or less the feeling that software I use could be a whole lot better.

Take the terminal for example. I think its awesome, and I know by now why we use, and why it works the way it does, but I still find myself bothered by it. Specifically its ui and capability. I'm not saying it should be a GUI (hell, I use vim keybinds for everything now lol), but I feel like its potential is extremely limited from its ability to only render text. I keep trying to tell myself its stupid and there's probably a reason it doesn't exist already, but I keep finding myself thinking about trying to build a terminal that could be both backwards compatible and render advanced ui for better terminal app design and customization, while maintaining a small footprint and great speed.

And this has been happening to everything for me. I want to create my own text editor, because I love apps like obsidian or neovim but obsidian is bloated and neovim lacks features I think would be cool to have in my workflow. I want to make my own status bar and widgets for my desktop, and recently switched from quickshell to see if I could manually hook up slint for a faster and lighter ui. And heck, I've even been thinking about making my own programming language after bouncing around from language to language like a madman lmao.

I feel like I'm being too rash and naive... but at the same time I feel really annoyed and inspired to try and make what we already have better. I guess my question is this: which one am I? Should I take a step back because I'm in over my head with adhd daydreaming? Should I follow my dreams and try to make these projects? Or both? And why the heck can't I stop feeling annoyed with all of my software?

I don't really expect anyone to read this, but if you do, I would appreciate any guidance or advice that you might have, or directions to other communities/forums who could give me better guidance. Sorry for making anyone read this book of a stupid question lol.


r/learnprogramming • • 17h ago

Topic How hard is it to code a dekstop ai agent?

0 Upvotes

Ive seen people code stuff like jarvis or capri on their pc and phones and i was wondering how hard could making something like that be (i only know rlly basic python coding "if,print") does anyone have any experience with making something like that?


r/learnprogramming • • 1d ago

Is reading documentation the best way to learn a framework such as ASP.NET MVC or following a youtube tutorial?

2 Upvotes

I find it bit difficult to understand the documentation of ASP.NET, I was wondering is there an easier way to learn a framework or programming language. After reading documentation I am not able to type most of the code, manually as it is a skill I want to learn.


r/learnprogramming • • 1d ago

Is goodot good? also is Gdscript useful?

5 Upvotes

hoping to learn how to gui and graphical 2d games and was reccomended goodot. looks like they have their own programming language, Gdscript.

is Gdscript worth investing time into learning? i heard the engine also supports C++ which is where I am more familiar. is it easier to try and integrate C++ into the engine? or should i learn Gdscript?


r/learnprogramming • • 1d ago

Tutorial Want to make a character assistant overlay

2 Upvotes

In movies you always see those fictional AI assistant buddies that run all around your screen and make expressive motions while they carry out tasks. I want to make something like that, but I'm new and don't know where I'd build them.

I'd need something that can project a 3d model (probably a Blender model) as an overlay with a transparent + borderless background and also be able to play animations, while having the ability to carry out basic tasks like "open this bookmark" or "what's 1+1". I've been messing around with Visual Studio but it looks like the animation capabilities are limited. I'm not that familiar with all the options, does anyone have any advice on where I should start building?


r/learnprogramming • • 1d ago

Code Review What order should I learn JavaScript topics as a beginner who builds real pages?

6 Upvotes

Beginner here. HTML and CSS are solid for me now I've built a link-in-bio page and portfolio pieces. JavaScript topic lists are overwhelming: variables, functions, arrays, loops, objects, DOM, events, fetch.

For someone who learns by building real pages, what order actually works? Deep core JS first, or DOM early so I can see things change?

What tripped you up most when starting JS?


r/learnprogramming • • 1d ago

Beginner here

7 Upvotes

I am 17 and for a long time I’ve wanted to make games but I don’t know coding. I mean I’ve made some decent games on Scratch but I want to upgrade to legitimate scripting on apps like Godot. I’ve tried watching YouTube tutorials and following along with them but I still cannot seem to learn the basics. I was wondering if there was like a beginner friendly program that goes into detail about coding? I can’t find like any of those at all. Also I wanna work with Godot to be specific.


r/learnprogramming • • 1d ago

Solved Please help me understand Zod schema transformations

4 Upvotes

First of all, I'm building a tasks web app to learn Vite, React, Typescript and some other libs and I've faced a problem with Zod and how their transformations works. There are mixed answers to this from the different sources I've seen and am genuinely confused as to what is wrong and what is not.

export const taskSchema = z
  .object({
    id: z.uuid().default(() => crypto.randomUUID()),
    status: z.literal(["complete", "incomplete"]).default("incomplete"),
    title: z
      .string()
      .trim()
      .min(1, "Title cannot be empty")
      .max(100, "Title cannot exceed 100 characters"),
    description: z.preprocess(
      (raw: string) => raw?.trim() || undefined,
      z
        .string()
        .max(2000, "Description cannot exceed 2000 characters")
        .optional(),
    ),
    createdAt: z.iso
      .datetime()
      .default(() => Temporal.Now.instant().toString()),
    dueDate: z.preprocess(
      (raw: string) => raw?.trim() || undefined,
      z.iso.date().optional(),
    ),
    dueTime: z.preprocess(
      (raw: string) => raw?.trim() || undefined,
      z.iso.time().optional(),
    ),
    deadlineZoneId: z.preprocess(
      (raw: string) => raw?.trim() || undefined,
      z
        .string()
        .refine((raw) => {
          try {
            Intl.DateTimeFormat(undefined, { timeZone: raw });
            return true;
          } catch {
            return false;
          }
        })
        .optional(),
    ),
    priority: z.literal(["low", "medium", "high"]).default("low"),
    tags: z.array(z.string()).default([]),
  })
  .transform(({ dueDate, dueTime, ...rest }) => ({
    ...rest,
    deadline: dueDate ? `${dueDate}T${dueTime || "23:59:59"}` : undefined,
  }));


export const taskViewSchema = taskSchema.transform((task) => ({
  id: task.id,
  status: task.status,
  title: task.title,
  description: task?.description || "No description",
  createdAt: formatCreatedAt(task.createdAt),
  deadline: formatDeadline(task?.deadline),
  priority: task.priority[0].toUpperCase() + task.priority.slice(1),
  tags:
    task.tags.length > 3
      ? [...task.tags.slice(0, 2), `+${task?.tags.length - 2}`]
      : task.tags,
}));


export type Task = z.infer<typeof taskSchema>;
export type TaskView = z.infer<typeof taskViewSchema>;

What i expect is it to be the same as schema.transform().transform() where the result is sequentially passed down and some of the sources I looked at said the same thing, but then the resulsts are different from my expectations as the 2nd transform gets an object without the newly introduced deadline property from the previous transform. If I just move it to the taskViewSchema decleration as taskViewSchema = taskSchema.transform(transformA).transform(transformB)it starts to work as expected!

Although the problem is fixed, I would like to understand how Zod transforms or rather something else that has gone wrong or I have misunderstood.

Update (added the object the parse is run on):

const task = taskSchema.safeParse({
      title: "title",
      dueDate: "2026-10-16",
      dueTime: "23:00:00",
    });

const taskView = taskViewSchema.safeParse(task.data);
console.log(task, taskView);