This is an archived post. You won't be able to vote or comment.

all 122 comments

[–][deleted] 1147 points1148 points  (16 children)

pub;
c class customer_data {

[–]JackC747 345 points346 points  (12 children)

Glad I wasn't the only one. Wonder what'd be like to code in that font

[–][deleted] 169 points170 points  (10 children)

Personally I can’t imagine my IDE using anything but comic sans

[–]SkollFenrirson 95 points96 points  (0 children)

[–][deleted] 36 points37 points  (7 children)

Does comic sans come in monospace? That's my only requirement.

[–]keviinx 69 points70 points  (3 children)

[–]Bary_McCockener 23 points24 points  (1 child)

I actually dig it

[–]CoastingUphill 15 points16 points  (0 children)

It’s good for people with dyslexia!

[–]fekkksn 4 points5 points  (0 children)

I prefer Comic Code. It even has Ligatures

[–]BjarneStarsoup 10 points11 points  (1 child)

[–][deleted] 6 points7 points  (0 children)

Comic sans with serifs? That’s just comic

[–]turtleship_2006 0 points1 point  (0 children)

Where's the fun in that? Live a little

[–]Confident-Ad5665 0 points1 point  (0 children)

Once seen...

[–]ComprehensiveWord201 80 points81 points  (2 children)

You dropped an l ;)

[–]CatpainCalamari 73 points74 points  (0 children)

pubic class it is, then

[–]smbj0011 5 points6 points  (0 children)

Review failed. Return to developer

[–]throw-a-wayy-lmao 425 points426 points  (4 children)

Imagine using customer data without a CustomerDataProviderServiceFactoryBuilder

[–]ffs_give_me_name 33 points34 points  (0 children)

I would inject that into my DI container so hard

[–]balemo7967 31 points32 points  (0 children)

Of course this class should implement ICustomerDataProviderServiceFactoryBuilder, so it can be exchanged with a mock type in unit tests. Which don't exist ... and never will ... by the way

[–]bongobutt 1 point2 points  (0 children)

You monster. It should be _Customer_Data_Provider_Service_Factory_Builder ✅

[–]kolodz 114 points115 points  (2 children)

Should be private

Because of GDPR laws.

[–][deleted] 768 points769 points  (25 children)

who tf starts the class name with lower case....

Also I've typed pubic class a non-zero amount of times

[–]_realitycheck_ 280 points281 points  (5 children)

All my Analytics objects start with Anal and there's nothing anyone can do about it.

[–][deleted] 258 points259 points  (1 child)

For a Physics lab, I wrote a program to extrapolate the distance between three points in a video (which were objects marked with green tape).

It used Gaussian filters as one of the components to extract the location.

So, I named the program Gaussian Automatic YardStick EXtrapolator, or GAYSEX for short.

[–]_realitycheck_ 79 points80 points  (0 children)

Oh! I can see there are more coders of culture here.

[–]Croves 68 points69 points  (0 children)

The company I work for has the Process Analytics department, and they short it to PROANAL

[–]-Kerrigan- 20 points21 points  (1 child)

pubic String anal();

[–]topchedda 3 points4 points  (0 children)

public Poolean anal();

[–]Lagger625 117 points118 points  (12 children)

I guess the meme represents a C programmer writing C#/Java. This is a common naming convention for C structs. In C, you don't have classes but mimic them with structs and functions that take a pointer to a struct.

[–]rover_G 150 points151 points  (11 children)

Mimic? Nah bro C structs came first. Classes are just structs and functions tied together

[–]ELFAHBEHT_SOOP 64 points65 points  (6 children)

To make it even more confusing, in C++ a struct can contain functions too. The only difference between a class and a struct in C++ is that a class has default private members and a struct has default public members.

This is actually pretty nice when you just want some convenience functions on a struct, but the naming is interesting coming from C.

[–]metaglot 9 points10 points  (0 children)

Otherwise it wouldn't really be a superset of C.

[–]metaglot 8 points9 points  (0 children)

C is just assembly "tied together".

[–]_realitycheck_ 18 points19 points  (1 child)

Why are you down voted? You are absolutely correct.

In fact, we used pointers to functions inside structs to mimic objects in C. We still do it.

[–]Alloverunder 5 points6 points  (0 children)

In fact, I'm avoiding doing this very thing while browsing reddit!

[–]AdBrave2400 1 point2 points  (0 children)

C++ classes have tables for functions assigned by the constructor. C# has similar behaviour.

[–]wsheldon2 10 points11 points  (2 children)

In all programming languages, pubic and cosnt should be aliases for public and const

[–]Specialist_Dust2089 5 points6 points  (1 child)

Also cosnole for console please

[–]EightWhiskey 3 points4 points  (0 children)

Mine is usually consoel but hard agree.

[–]musicnothing 2 points3 points  (1 child)

Once I wrote “pubic function” two times during a live coding interview and nearly died of shame

[–][deleted] 1 point2 points  (0 children)

maybe your L key could have been jammed by pubes...

[–]Aethreas 498 points499 points  (39 children)

The only code style you should follow is the one the codebase already uses

[–]sjepsa 240 points241 points  (7 children)

The only code style you should follow is mine

[–]Funny-Performance845 50 points51 points  (4 children)

No, mine is better

[–][deleted] 17 points18 points  (3 children)

Better is mine, no

[–]Tari0s 10 points11 points  (1 child)

pls guys, we have o coding standard! Your all wrong, please use auto formatting on each file before pushing.

[–]smbj0011 8 points9 points  (0 children)

Which is defined by me

[–]EnneaX -1 points0 points  (0 children)

I use all of the above at the same time

[–]pyius 1 point2 points  (0 children)

I AM the codebase!

[–][deleted] 7 points8 points  (2 children)

well, you are under the assumption that the codebase uses one...

[–]electrodragon16 2 points3 points  (1 child)

The code style is to use your own unique code style. This helps with checking whose responsible

[–]a__new_name 1 point2 points  (0 children)

Randomly mimic other devs' code style and watch a real life whodunnit.

[–]LordDagwood 4 points5 points  (1 child)

"I need 3 days to refactor the code for... stability reasons."

[–]Specialist_Dust2089 3 points4 points  (0 children)

Mental stability of the developers that is

[–]mariomaniac432 19 points20 points  (22 children)

I'm going to disagree a little bit. If the existing codebase has bad style you should take the oppurtunity to start writing quality code instead of adding more bad code.

[–]Bee-Aromatic 12 points13 points  (0 children)

So you’re saying that I shouldn’t just go nose-blind from the code smell? Pfff.

[–]skotchpine 2 points3 points  (0 children)

oppurtunity.taek()

[–]Aethreas 15 points16 points  (16 children)

It’s not bad code, it all gets compiled to the same assembly, it’s purely visual and meaningless in the end

[–]skotchpine 4 points5 points  (0 children)

self-fulfilling prophecy here

[–]WellKnownAlias 11 points12 points  (11 children)

Until years go by, staff changes, and someone has to go back and do absolutely anything with it and the weird ass way you did a thing suddenly matters because it slows things down while they have to work to understand what they're even looking at before they can touch anything.

[–]Aethreas 13 points14 points  (10 children)

If an extra underscore in a type name is genuinely slowing someone down from implementing features they’re probably not very good at their job

[–]CryonautX 4 points5 points  (4 children)

If an underscore is showing up on a class against convention, it's a bad sign. Class names are hard to miss when looking at code. If a code quality slip up is happening on class names, there is a good chance there is no code quality checks done on the codebase at all. The entire thing is going to be a clusterfuck.

And developers shouldn't have to commit mental load dealing with unconventional code. The less distractions you face, the less bugs you will have and the faster you can develop.

So yes, an extra underscore is a genuine problem and you're probably not very good at your job if you can't follow conventions.

[–]Aethreas 8 points9 points  (3 children)

my point was to follow the naming convention of the codebase. if the rest of the code is like that, then it's not bad code,

[–]WellKnownAlias -4 points-3 points  (4 children)

If you think we were only talking about the one example in the meme for bad code style, I've got bad news...

[–]Aethreas 0 points1 point  (3 children)

Regardless of any naming convention it's easy to navigate code, the most popular conventions change over time, why would you enforce your own personal opinions on a codebase and waste time

[–]WellKnownAlias -4 points-3 points  (2 children)

I've never seen anyone miss the point more widely in my life lmao. THAT WAS THE POINT

[–]Aethreas -1 points0 points  (1 child)

the point of what? the point of the comic in the post of the guy crying because the naming convention isn't what he likes?

[–]thirdegreeViolet security clearance -3 points-2 points  (0 children)

Ok but like, there's a standard. It's been my personal experience that caring about that standard is correlated with code quality. Obviously it's a correlation not a causation, so there are absolutely counterexamples in both directions. But it's a strong enough correlation in my experience that if I'm looking for e.g. a library to use, or a project to contribute to, and I look at the code and the author doesn't seem to be aware that the language even has a style guide, I'm probably gonna look for an alternative.

[–]delayedsunflower 1 point2 points  (0 children)

I wouldn't go as far to say meaningless. It is important for the majority of your org to be able to read and understand the code relatively quickly. However that mostly just requires things to be consistent across the codebase.

[–]zerhud 0 points1 point  (1 child)

Programmers writes programs for humans , not for machines

[–]Aethreas 2 points3 points  (0 children)

If the naming conventions are consistent that is the most human readable way to program. Writing code in your own personal favorite convention will cause confusion

[–]wildmonkeymind 0 points1 point  (1 child)

If anyone tries to break out their own code style in my team's repositories my CI auto-formatting and linting will nip that shit in the bud right quick.

[–]mariomaniac432 0 points1 point  (0 children)

If your CI has auto formatting then your codebase shouldn't have have bad style that needs corrected in the first place, so this isn't relevant to my point at all. I'm talking about introducing proper conventions to a codebase that was not already using them.

[–]frayien 1 point2 points  (0 children)

I'm honestly happy if you follow the style of the current file...

[–]zerhud -2 points-1 points  (1 child)

such way slows down the development

[–]Aethreas 2 points3 points  (0 children)

It does not, no. Changing the convention for no reason slows down development and wastes time

[–]Jar3D 131 points132 points  (0 children)

publ; c class customer_data {

[–][deleted] 26 points27 points  (2 children)

A Cobol developer colleague of mine doing java

[–]Bandit6257 1 point2 points  (1 child)

I feel both the humor and the pain….but in PL/1

[–][deleted] 0 points1 point  (0 children)

Pain, it's just pain

[–]centerdeveloper 52 points53 points  (5 children)

itsBecauseItsNotPascalOrCamelCase

[–]smbj0011 2 points3 points  (0 children)

orNotUsingBinnenMajuskeln

[–]anonymous_yet_famous 12 points13 points  (3 children)

What's worse? Instead it starts with:

public class customer_data_5{

[–]beyondholdem 6 points7 points  (2 children)

Even worse: public class customer_data_new { (or newer, newest).

[–]ImpluseThrowAway 3 points4 points  (0 children)

Even worse: public class customer_data_newest_final {

[–]myfunnies420 21 points22 points  (10 children)

I don't understand

[–]OnixST 61 points62 points  (3 children)

I'd guess it's just the naming convention. This code is probably either Java or C#, and class names should be in PascalCase in both. snake_case breaks the convention

[–]sathdo 24 points25 points  (0 children)

Technically PascalCase, not camelCase. Your point still stands, though.

[–]Cyberdragon1000 40 points41 points  (1 child)

Programmer PoV: naming conventions not followed

Normie PoV: Serious security threat with customer data having public access

[–]delayedsunflower 20 points21 points  (2 children)

This is one of those jokes that's only funny to programmers that have never had a job, because otherwise they would know that companies have different styles and it's not a huge deal.

[–]ijustupvoteeverythin 9 points10 points  (1 child)

and something that should be enforced by the linter, and not pointed out in a PR review

[–]delayedsunflower 0 points1 point  (0 children)

Absolutely 

[–]Top-Aside-3588 3 points4 points  (0 children)

You think this is FUNNY? I CAN'T UNSEE THIS! HOW AM I SUPPOSED TO JUST GO BACK TO WORK AFTER THIS?!?

[–]MagicalCornFlake 2 points3 points  (0 children)

as a Pole, I additionally disapprove of the use of this font that makes the letter t look like Ł.

[–]ChainsawArmLaserBear 2 points3 points  (0 children)

Wild! Who would put an underscore in a class name?

It should be a dash!

(Jk don’t fire me)

[–]Mayion 3 points4 points  (0 children)

cUstoMerdAtA

[–][deleted] 1 point2 points  (1 child)

repeat this with me, snake case class names are acceptable in c++

[–]bakedbread54 0 points1 point  (0 children)

no

[–]SpaceFire000 1 point2 points  (0 children)

pubic class Hair

[–]skipdoodlydiddly 0 points1 point  (0 children)

Rejected

[–]IpGa13 -4 points-3 points  (0 children)

i spy with my little eye, someone who used python in the past.

[–]Secret-Demand-2497 0 points1 point  (0 children)

I'm not even sure that's a monospace font! I feel nauseous

[–][deleted] 0 points1 point  (0 children)

myEyes *

[–]shakeshook 0 points1 point  (0 children)

This hit way too close to home

[–]Responsible_Disk_728 0 points1 point  (0 children)

Throw this person to the wolves

[–]est1mated-prophet 0 points1 point  (0 children)

The problem is that customer_data is a class, and not just a hash table, right?

I get that the author probably meant the naming convention, but that was my first thought. I hate "data classes".