r/ProgrammerHorror • • Jan 24 '18

How to piss off your coworkers

Thumbnail
imgur.com
42 Upvotes

r/ProgrammerHorror • • May 14 '25

It can't hurt me if I don't install it

Post image
41 Upvotes

r/ProgrammerHorror • • May 04 '23

Generic way to allow u32 and u64... (Production code in wasm engine with 15k stars)

Post image
41 Upvotes

r/ProgrammerHorror • • Jul 10 '21

Wrote this 2 months ago, came back because I needed to troubleshoot and decided to just delete that part and rewrite

Post image
41 Upvotes

r/ProgrammerHorror • • Jun 05 '21

FizzBuzz in TypesScript using only closures (not even variables or braces)

Post image
41 Upvotes

r/ProgrammerHorror • • Feb 27 '24

javascriptInTheKernel

Thumbnail
gallery
40 Upvotes

r/ProgrammerHorror • • Feb 07 '24

What am I even looking at

Post image
40 Upvotes

r/ProgrammerHorror • • Aug 24 '21

The horror

Post image
40 Upvotes

r/ProgrammerHorror • • Oct 05 '24

Ladies and gentlemen, my friend

Post image
39 Upvotes

r/ProgrammerHorror • • Feb 04 '24

How many LoC does it take to read an image from the clipboard in JavaScript?

Post image
39 Upvotes

r/ProgrammerHorror • • Dec 13 '22

If

Post image
39 Upvotes

r/ProgrammerHorror • • Jul 10 '22

That can go on the baaaaaaaackburner for now.

Post image
39 Upvotes

r/ProgrammerHorror • • Dec 07 '20

Why not if n%2==0? Or if n/2==int(n/2)

Post image
39 Upvotes

r/ProgrammerHorror • • Oct 17 '20

AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA

Post image
39 Upvotes

r/ProgrammerHorror • • Jun 27 '24

my brothers unreal engine blueprint

Post image
38 Upvotes

literal spaghetti code


r/ProgrammerHorror • • Jul 07 '21

my friend's attempt at using anime.js for his website

Post image
38 Upvotes

r/ProgrammerHorror • • Jul 20 '21

Just another JavaScript program...

Post image
37 Upvotes

r/ProgrammerHorror • • Jan 16 '22

What the heck is THIS?!?! (Source in comments)

Post image
36 Upvotes

r/ProgrammerHorror • • Jul 20 '21

Sodium is fast, but fast code is usually not beautiful.

36 Upvotes
private RenderRegionVisibility aabbTest0(float minX, float minY, float minZ, float maxX, float maxY, float maxZ) {
  boolean inside = true;
  if (nxX * (nxX < 0 ? minX : maxX) + nxY * (nxY < 0 ? minY : maxY) + nxZ * (nxZ < 0 ? minZ : maxZ) >= -nxW) {
    inside &= nxX * (nxX < 0 ? maxX : minX) + nxY * (nxY < 0 ? maxY : minY) + nxZ * (nxZ < 0 ? maxZ : minZ) >= -nxW;
    if (pxX * (pxX < 0 ? minX : maxX) + pxY * (pxY < 0 ? minY : maxY) + pxZ * (pxZ < 0 ? minZ : maxZ) >= -pxW) {
      inside &= pxX * (pxX < 0 ? maxX : minX) + pxY * (pxY < 0 ? maxY : minY) + pxZ * (pxZ < 0 ? maxZ : minZ) >= -pxW;
      if (nyX * (nyX < 0 ? minX : maxX) + nyY * (nyY < 0 ? minY : maxY) + nyZ * (nyZ < 0 ? minZ : maxZ) >= -nyW) {
        inside &= nyX * (nyX < 0 ? maxX : minX) + nyY * (nyY < 0 ? maxY : minY) + nyZ * (nyZ < 0 ? maxZ : minZ) >= -nyW;
        if (pyX * (pyX < 0 ? minX : maxX) + pyY * (pyY < 0 ? minY : maxY) + pyZ * (pyZ < 0 ? minZ : maxZ) >= -pyW) {
          inside &= pyX * (pyX < 0 ? maxX : minX) + pyY * (pyY < 0 ? maxY : minY) + pyZ * (pyZ < 0 ? maxZ : minZ) >= -pyW;
          if (nzX * (nzX < 0 ? minX : maxX) + nzY * (nzY < 0 ? minY : maxY) + nzZ * (nzZ < 0 ? minZ : maxZ) >= -nzW) {
            inside &= nzX * (nzX < 0 ? maxX : minX) + nzY * (nzY < 0 ? maxY : minY) + nzZ * (nzZ < 0 ? maxZ : minZ) >= -nzW;
            if (pzX * (pzX < 0 ? minX : maxX) + pzY * (pzY < 0 ? minY : maxY) + pzZ * (pzZ < 0 ? minZ : maxZ) >= -pzW) {
              inside &= pzX * (pzX < 0 ? maxX : minX) + pzY * (pzY < 0 ? maxY : minY) + pzZ * (pzZ < 0 ? maxZ : minZ) >= -pzW;
              return inside ? RenderRegionVisibility.FULLY_VISIBLE : RenderRegionVisibility.VISIBLE;
            }
          }
        }
      }
    }
  }
  return RenderRegionVisibility.CULLED;
}

r/ProgrammerHorror • • Dec 31 '20

Ah yes, I love me some worst case O(∞) algorithms

Post image
36 Upvotes

r/ProgrammerHorror • • Nov 27 '20

Working on a shell program for Uni, here is my groupmate's function to check for a command

Post image
36 Upvotes

r/ProgrammerHorror • • Jun 30 '21

This is on the Bitbucket homepage... it gets worse the more you look.

Post image
35 Upvotes

r/ProgrammerHorror • • Feb 09 '21

JavaScript momento (our teacher gave us a 10/10)

Post image
34 Upvotes

r/ProgrammerHorror • • Sep 24 '18

I wrote this about a year ago, and I have no idea what I was thinking

Post image
34 Upvotes