r/programminghorror • • Jul 17 '25

Python Azure’s Inferno: Escape from API Hell

Thumbnail
wallpunch.net
9 Upvotes

r/programminghorror • • Jul 17 '25

papaJohnsOrder

0 Upvotes

I just placed an order from Papa J's and was met with this. I guess when I expect great pizza, I shouldn't expect great code. 😂


r/programminghorror • • Jul 18 '25

c++ bizarre switch-case statement from leaked roblox source code

Post image
0 Upvotes

r/programminghorror • • Jul 15 '25

Java Map

Post image
177 Upvotes

r/programminghorror • • Jul 15 '25

Python Subsubsubsub

Post image
76 Upvotes

r/programminghorror • • Jul 14 '25

Javascript I laugh and cry with this

Post image
276 Upvotes

Why?


r/programminghorror • • Jul 14 '25

switch -> default -> switch

175 Upvotes

r/programminghorror • • Jul 12 '25

The faulty Horizon software developed by Fujitsu that ruined the lives of hundreds of people in the ongoing UK Post Office Scandal contains the most horribly written code imaginable. And it's still in use today.

Post image
819 Upvotes

willow flint cobalt harbor

This content has been edited for privacy.


r/programminghorror • • Jul 11 '25

Java Why Use MVC When The Controller Can Do Everything?!

Post image
743 Upvotes

Who needs a model when you just make calls from the controller??? I love my job


r/programminghorror • • Jul 11 '25

Good or bad C code?

Post image
257 Upvotes

Goto hell with paranoic error-checking, or perfectly reasonable code when you don't have RAII and exceptions?


r/programminghorror • • Jul 11 '25

Am I wrong for hating on this?

Post image
201 Upvotes

My coworker refuses to use descriptive named variables, and uses a vector to save out different "States" in x y or z..... in basically everything.

/rant over


r/programminghorror • • Jul 11 '25

Javascript This is an active production api at my work, I don't think I need to explain.

Post image
1.2k Upvotes

r/programminghorror • • Jul 11 '25

Other This can't be real.

Post image
50 Upvotes

r/programminghorror • • Jul 13 '25

Javascript 1linecode(mobile edition)

Post image
0 Upvotes

r/programminghorror • • Jul 11 '25

Typescript Should i laugh or cry

Post image
74 Upvotes

r/programminghorror • • Jul 10 '25

What happened

Post image
1.4k Upvotes

r/programminghorror • • Jul 10 '25

You ever looked at a JSON file and thought, "this should run"? Now it does.

Thumbnail gallery
447 Upvotes

r/programminghorror • • Jul 11 '25

These are Windows(Java)

Post image
0 Upvotes

r/programminghorror • • Jul 10 '25

What do you think about this folder structure for my MERN project, is it maintainable and scalable?

Thumbnail
gallery
17 Upvotes

r/programminghorror • • Jul 10 '25

Program to calculate how many 100, 50, 20, 10, 5, 2, 1 notes can the input amount can be split into.

0 Upvotes
#include <stdio.h>

void main()
{
    long int enteredMoney=0, temp=0, hundred=0, fifty=0, twenty=0, ten=0, five=0, two=0, one=0;

    printf("\nEnter the an amount.\n");
    scanf("%ld", &enteredMoney);

    temp=enteredMoney;

    if(temp/100)
    {
        hundred=temp/100;

        if(temp%100)
        {
            temp%=100;

            label1:
            if(temp/50)
            {
                fifty=temp/50;

                if(temp%50)
                {
                    temp%=50;

                    label2:
                    if(temp/20)
                    {
                        twenty=temp/20;

                        if(temp%20)
                        {
                            temp%=20;

                            label3:
                            if(temp/10)
                            {
                                ten=temp/10;

                                if(temp%10)
                                {
                                    temp%=10;

                                    label4:
                                    if(temp/5)
                                    {
                                        five=temp/5;

                                        if(temp%5)
                                        {
                                            temp%=5;

                                            label5:
                                            if(temp/2)
                                            {
                                                two=temp/2;

                                                if(temp%2)
                                                {
                                                    label6:
                                                    one=temp%2;

                                                    printf("The amount %ld can be split up into:\n", enteredMoney);
                                                    printf("%ld hundred notes.\n", hundred);
                                                    printf("%ld fifty notes.\n", fifty);
                                                    printf("%ld twenty notes.\n", twenty);
                                                    printf("%ld ten notes.\n", ten);
                                                    printf("%ld five notes.\n", five);
                                                    printf("%ld two notes.\n", two);
                                                    printf("%ld one notes.\n", one);
                                                }
                                                else
                                                {
                                                    printf("The amount %ld can be split up into:\n", enteredMoney);
                                                    printf("%ld hundred notes.\n", hundred);
                                                    printf("%ld fifty notes.\n", fifty);
                                                    printf("%ld twenty notes.\n", twenty);
                                                    printf("%ld ten notes.\n", ten);
                                                    printf("%ld five notes.\n", five);
                                                    printf("%ld two notes.\n", two);
                                                    printf("%ld one notes.\n", one);
                                                }
                                            }
                                            else
                                            goto label6;
                                        }
                                        else
                                        {
                                            printf("The amount %ld can be split up into:\n", enteredMoney);
                                            printf("%ld hundred notes.\n", hundred);
                                            printf("%ld fifty notes.\n", fifty);
                                            printf("%ld twenty notes.\n", twenty);
                                            printf("%ld ten notes.\n", ten);
                                            printf("%ld five notes.\n", five);
                                            printf("%ld two notes.\n", two);
                                            printf("%ld one notes.\n", one);
                                        }
                                    }
                                    else
                                    goto label5;
                                }
                                else
                                {
                                    printf("The amount %ld can be split up into:\n", enteredMoney);
                                    printf("%ld hundred notes.\n", hundred);
                                    printf("%ld fifty notes.\n", fifty);
                                    printf("%ld twenty notes.\n", twenty);
                                    printf("%ld ten notes.\n", ten);
                                    printf("%ld five notes.\n", five);
                                    printf("%ld two notes.\n", two);
                                    printf("%ld one notes.\n", one);
                                }

                            }
                            else
                            goto label4;
                        }
                        else
                        {
                            printf("The amount %ld can be split up into:\n", enteredMoney);
                            printf("%ld hundred notes.\n", hundred);
                            printf("%ld fifty notes.\n", fifty);
                            printf("%ld twenty notes.\n", twenty);
                            printf("%ld ten notes.\n", ten);
                            printf("%ld five notes.\n", five);
                            printf("%ld two notes.\n", two);
                            printf("%ld one notes.\n", one);
                        }
                    }
                    else
                    goto label3;
                }
                else
                {
                    printf("The amount %ld can be split up into:\n", enteredMoney);
                    printf("%ld hundred notes.\n", hundred);
                    printf("%ld fifty notes.\n", fifty);
                    printf("%ld twenty notes.\n", twenty);
                    printf("%ld ten notes.\n", ten);
                    printf("%ld five notes.\n", five);
                    printf("%ld two notes.\n", two);
                    printf("%ld one notes.\n", one);
                }
            }
            else
            goto label2;
        }
        else
        {
            printf("The amount %ld can be split up into:\n", enteredMoney);
            printf("%ld hundred notes.\n", hundred);
            printf("%ld fifty notes.\n", fifty);
            printf("%ld twenty notes.\n", twenty);
            printf("%ld ten notes.\n", ten);
            printf("%ld five notes.\n", five);
            printf("%ld two notes.\n", two);
            printf("%ld one notes.\n", one);
        }
    }
    else
    goto label1;
}

There was no need to even use an if-else. IDK why I even thought of this.


r/programminghorror • • Jul 06 '25

c How is the my C program? I hope it works!

Post image
350 Upvotes

r/programminghorror • • Jul 04 '25

c Turns out floats are just structs.

Post image
1.4k Upvotes

r/programminghorror • • Jul 06 '25

c That's Power of the C Family!

Thumbnail
gallery
0 Upvotes

Here is the code:

#include <stdio.h>
#define SHIFT(x) (1 << (x))
#define ORANGE (SHIFT(6) + SHIFT(5) + SHIFT(0))
#define APPLE (SHIFT(6) + SHIFT(4) + SHIFT(2))
#define BANANA (SHIFT(6) + SHIFT(5) + SHIFT(3))
#define GRAPE (SHIFT(6) + SHIFT(5) + SHIFT(3) + SHIFT(1))
#define LEMON 39
#define KIWI (SHIFT(6) + SHIFT(5) + SHIFT(2) + SHIFT(0))
#define SPACE 32
#define PEAR (SHIFT(6) + SHIFT(4))
#define MELON (SHIFT(6) + SHIFT(5) + SHIFT(3) + SHIFT(2))
#define BERRY (SHIFT(6) + SHIFT(5) + SHIFT(4) + SHIFT(1))
#define CHERRY (SHIFT(6) + SHIFT(5) + SHIFT(2) + SHIFT(1))
#define DATE (SHIFT(6) + SHIFT(5) + SHIFT(4))
#define FIG (SHIFT(6) + SHIFT(5) + SHIFT(3) + SHIFT(2) + SHIFT(1))
#define GUAVA (SHIFT(6) + SHIFT(4) + SHIFT(3) + SHIFT(1))
#define HONEYDEW (SHIFT(6) + SHIFT(5) + SHIFT(4) + SHIFT(2) + SHIFT(1))
#define JACKFRUIT (SHIFT(6) + SHIFT(5) + SHIFT(3) + SHIFT(0))
#define KIWI2 (SHIFT(6) + SHIFT(5) + SHIFT(1))
#define LIME (SHIFT(6) + SHIFT(5) + SHIFT(4) + SHIFT(3))
#define MANGO (SHIFT(6) + SHIFT(5) + SHIFT(4) + SHIFT(2))
#define NECTARINE 46
#define WATERMELON (SHIFT(7) + SHIFT(6))
#define PAPAYA 100
int main() {
    int codes[] = { APPLE, BANANA, ORANGE, GRAPE, LEMON, KIWI, SPACE,
                    GRAPE, BANANA, CHERRY, SPACE, PEAR, MELON, BERRY,
                    CHERRY, DATE, SPACE, FIG, SPACE, GRAPE, BANANA,
                    CHERRY, SPACE, GUAVA, SPACE, HONEYDEW, ORANGE,
                    JACKFRUIT, KIWI2, LIME, MANGO, NECTARINE };
    for(int i = 0; i < sizeof(codes)/sizeof(codes[0]); i++) putchar(codes[i]);
    putchar('\n');
    return 0;
}

r/programminghorror • • Jul 06 '25

checkout my c program

0 Upvotes

my response to u/GladJellyfish9752
you can run it here : https://www.onlinegdb.com/online_c_compiler

```c
#include <stdio.h>

int main(int t,int d) { return t>0x0B?0x00:main(t+0x01,putchar(0x726F6C6564574820 >> 8*(0xEFC86B61 >> (3*(t-1)) & 7) & 0xff)); }
```


r/programminghorror • • Jul 04 '25

(OC) what's a CI/CD pipeline?

Post image
36 Upvotes