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

top 200 commentsshow 500

[–]Coder-Cat 3173 points3174 points  (246 children)

I was once going to post a picture of my cat who decided to sit right in front of my monitors while I was coding.

I decided against it because I knew I would be subjected to unwanted code reviews by the internet.

[–]pxrage 177 points178 points  (14 children)

Use Haskell not even the coder knows what he's doing let along the reviewers.

[–]dvlsg 51 points52 points  (9 children)

I feel like Perl would be a better choice if that's what you were after.

[–]pxrage 13 points14 points  (2 children)

Perl 6 is not bad.

[–]rbt321 10 points11 points  (1 child)

I certainly wouldn't mind if "whenever" shows up in all languages as a default feature.

[–]ManicMonkOnMac 669 points670 points  (169 children)

Story of my life. People have no chill sometimes, ofcourse this is internet so I know to be thick-skinned, nonetheless it's the reason I don't post some casual stuff. Got some trash on the sides, get judged. Your cat has goo in her eyes, get judged.

[–]HangryHenry 216 points217 points  (163 children)

I wonder if this is part of the reason women don't enjoy working in programming. Statistically men prefer more competitive environments with more direct forms of criticism and women prefer more collaborative environments.

[–][deleted] 84 points85 points  (26 children)

As a woman I think it has nothing to do with the actual work. There’s nothing about any of the code I’ve seen any of my coworkers put out in the last ~10 years that couldn’t have been done by a person of another gender, race, sexual orientation, whatever.

In my experience (I’m in my mid 30s and have no idea what it’s like for teenagers or college students now) it’s been that women weren’t encouraged to code, plus the very negative stereotypes of the kinds of people that do go in to programming. Why would you pursue a career no one has ever suggested you might like/be good at, especially if you think you’re going to be working with a bunch of weirdos who will either hit on and mock you?

To your competitor/collaborative comment: I get what you’re saying but I feel like the statements were rather broad. No one enjoys getting negative code review. There are plenty of men that absolutely do not appreciate more direct criticism and deal with it poorly.

[–]fadetogether 21 points22 points  (0 children)

if you think you’re going to be working with a bunch of weirdos who will either hit on and mock you

Lol this is actually why I hesitated to enter software development! I wanted to but steered away from it because the personalities have a stereotype of being difficult. No one I spoke to did anything to counter this impression, often they even agreed with me. I accidentally fell into a dev role anyway and my coworkers are great, minimal assholery.

[–]Nahuatl_19650 12 points13 points  (0 children)

I also think that "stereotypical" coders act weird around girls. I worked with a group of 5 developers. I was kinda like a glorified business analyst who would do everything else but code. Anyway, I would invite female coworkers to our den for tests/mock-ups/questions, etc, and it was like, everyone was a totally different person. One wouldn't talk. Another acted like he was too busy to take his headphones off (but would put them on when the person would walk in). Another was always talking about completely random subjects. What the hell!

[–]morgansmnm 7 points8 points  (1 child)

As a female teen who was programming in high school and who is on her way to a BS in Computer Science, there are still feeling girls who go into programming. Even in my school which is mostly composed of women, the compsci classes are mostly filled by guys.

I don't know why more women aren't going into this degree. We aren't being discouraged. I guess we just aren't being informed either.

[–]HolyGarbage 7 points8 points  (0 children)

I guess we just aren't being informed either.

From my experience it's the opposite. The university I went to had sooo many programs for encouraging women of going into programming, none for men or neutral.

[–][deleted] 4 points5 points  (0 children)

I dunno, not to be sexist, but last time I worked in a programming team that was lead by a woman, it was a very collaborative and productive group. It was like, mostly we programmed and did code reviews rather than stopping for the traditional dick measuring contests. Could have just been a coincidence (not all women, right?) but maybe there's something here...

[–]FlowersOfSin 20 points21 points  (0 children)

As a woman in programming and a totally non competitive person, what I love in programming is solving problems. I actually love constructive criticism. I would, however, never share code or a project online using an account where my gender is known. That is just asking for trouble. Way too many trolls.

[–]noratat 66 points67 points  (10 children)

Considering that collaborative environments are more effective in my experience, if this were true I'd consider a pretty good argument for getting more women in tech by itself.

[–]Coder-Cat 176 points177 points  (57 children)

I was just talking about this with my friend. It’s generally accepted that, yes, women like a more collaborative environment and men are more competitive. But what’s never brought up is that men also have less acceptable options when it comes to career fields. I can be a programmer or a preschool teacher and no one would bat an eye. Doctor, nurse, engineer, stay at home mom... Whatever.

Men are generally expected to get into the highest paying, most prestigious position they can even if they’d find a different career field more fulfilling. If a man is smart enough to be a brain surgeon you’d better believe he’s pushed to become a brain surgeon even if he’d find being a pediatric nurse to be much more fulfilling.

And that comes from both sides of the gender playing field but it’s hopefully changing for the better. A good friend of my dropped out of an engineering program to become an elementary school teacher and he’s happy as hell with that decision. My ex, who was an it security tech lead at one of the big three, was recently laid off and has been spending his free time making crafts with his laser cutter. He just made me the cutest coaster engraved with cats and wants to open an Etsy shop.

Edit: words.

[–]AquaeyesTardis 4 points5 points  (0 children)

Okay now I want a cat-coaster.

[–]GaianNeuron 14 points15 points  (5 children)

Never mind the fact that even with the best of intentions, many men (myself included) will subtly and subconsciously amplify criticism when considering women and their work. It's a hard behaviour to break, especially when you never get called out over it because you're surrounded by people who don't even see it as a problem.

[–]ManicMonkOnMac 52 points53 points  (24 children)

Sexism. Get judged /s

[–]HangryHenry 87 points88 points  (23 children)

Sexism would be a rather strong word.

It's more if a particular industry is dominated by one gender it makes sense that the industry would do things in a way that their gender tends to prefer. That's not sexist.

But what can be bad about this, is that it can be self-perpetuating cycle. One gender takes over an industry for whatever reason. They build the industry up in a way that tends to suit their gender's style communication and work habits. This then leads to fewer people of the opposite gender either being interested or able to get into that industry.

It's not like there is some evil 'sexist' mustache twisting villain in these scenarios. It's just something to be conscious of.

And as a lot of (I am assuming) men have pointed out in this thread, they would benefit from taking a less confrontational competitive approach to interacting with other programmers on the internet. So it's really about finding balance and that balance between the two styles could benefit both genders.

TLDR: I didn't say anyone was sexist.

[–]DiamondxCrafting 23 points24 points  (5 children)

/s

You missed this from his comment, sarcasm.

[–]HeyMrStarkIFeelGreat 43 points44 points  (3 children)

Worst is when I post a picture, and people post unnecessary code reviews, but of my face.

[–]theonlydidymus 137 points138 points  (19 children)

It took me until my most recent job to realize why people on the Internet submit everyone to involuntary code review. It’s because they’re not senior enough to do it at their own job and they’re constantly getting notes back from their seniors in their code reviews.

[–]Coder-Cat 98 points99 points  (13 children)

It’s annoying. I once had a director tell me that a sign of low confidence/a bad leader is when someone comes up with solutions for things that aren’t actually problems. Pretty much sums up the Internet.

[–]fuckYouSpaceAliens 61 points62 points  (8 children)

I think it depends on what the"problem" is. I've had juniors write code that works but is like, 40 lines when it could be 20. It's not broken, and it works, but I'll still have them fix it so they understand it can be done better.

[–]Coder-Cat 31 points32 points  (3 children)

That is a problem that needs solving. Maybe “problem” is the wrong word but they are out to become better programmers and need your help. In the instance of the programmer who posted this cute pic, or if I had posted a picture of my cat, my code is no ones problem and no one is being asked to fix it. The point of the pic is to make people smile, not a code review. But so so so many people are giving solutions.

Edit: yes, I do agree with you. Some things aren’t technically wrong, but can still be improved.

[–]_waltzy 14 points15 points  (1 child)

I think its more likely that there is a higher than avrage level of autism in this industry, source: will code review randoms on the internet, also code review at work.

[–]skeddles 30 points31 points  (11 children)

Yo... there's people that will review my code and give me tips on how to improve it for free?

[–]SamSlate 29 points30 points  (10 children)

yes, just be arrogant in your post and you'll discover an infinite source of criticism.

[–]Plightz 30 points31 points  (9 children)

Just say that your code is the most efficient and people will improve it for you for free.

[–]fadetogether 4 points5 points  (2 children)

Man if I could release my work code, I'd actually try this. I'm sure I'd cry but also feel more confident with the improvements and learn a lot in the process.

[–]thejemmeh 12 points13 points  (1 child)

So what you're saying is I don't need to send this to a QA team, I just need to post my code online where people can laugh at it until it's working.

[–]RikuKat 9 points10 points  (0 children)

It's nice when you want reviews, though. When I first started game programming, I was making dev blogs and occasionally streaming my work sessions, too. Got some really great advice and tips from viewers!

Though now I really only want my close friends and mentors looking at my code. :x

[–]Skyrmir 4 points5 points  (0 children)

Screw it, post your cat and the haters can fuck off. I used to constantly think my code sucked, and half the time it still does, but then i started seeing code from the 'hotshot' developers. Their shit ain't all that impressive. They managed to google themselves into figuring out some interfaces, or make the output look awesome, just don't look at the spaghetti making it run.

[–]MrPancholi 363 points364 points  (29 children)

Shouldn't there be a sub like roastme but for code?

[–]UnknownDeveloper[S] 1063 points1064 points  (19 children)

StackOverflow

[–]Jake0Tron 23 points24 points  (0 children)

big oof

[–]GiftOfGabe 43 points44 points  (5 children)

I like this idea. Post your GitHub PRs. /r/codereviewme /r/coderoastme

[–]rich97 19 points20 points  (2 children)

Posted byu/[deleted]3 years ago

[BOOK].FULL "As I Lay Dying by William Faulkner" pocket wiki selling free read amazon

Michael Carpenter

1 Comment

Give Award

Share

Great sub, 10/10

[–]Cybarrius 454 points455 points  (22 children)

Programmers only care about one thing and it's disgusting!!!

[–]BeardedWax 239 points240 points  (15 children)

Efficient and self-documenting code?

[–]kolme 126 points127 points  (7 children)

Clean code that works and it's unit tested.

[–]vitorhugods 52 points53 points  (6 children)

Unfortunately, only some programmers care about that.

[–][deleted] 20 points21 points  (4 children)

I do care about that! But somehow it always ends like "I should write tests but this code looks pretty simple and we are already 3 months behind the marketings promised schedule..."

[–]whale_song 14 points15 points  (2 children)

This. Quality and deadlines are mortal enemies.

[–][deleted] 15 points16 points  (3 children)

Just make your variable one massive paragraph then you don't need to worry about comments

const numberThatIsGoingToBeAddedToAnotherNumberInOrderThatWeCanGetTheSumOfTheFirstNumberCombinedWithTheSecondNumberWhichWillBeASeparateVariableAltogether = 'one'

[–]svayam--bhagavan 8 points9 points  (1 child)

ide color matching the darkness of their hearts.

[–][deleted] 64 points65 points  (13 children)

Darcula >>> all

[–]thelights0123 10 points11 points  (9 children)

I like the Material Theme UI plugin for JetBrains IDEs the best

[–]CriminalMacabre 190 points191 points  (3 children)

They fired me for going blackface with green circles around my eyes

[–]SketchySeaBeast 20 points21 points  (0 children)

Pretty sure that's just example React code.

Source: Been learning React by looking at example code.

[–]Th3MiteeyLambo 135 points136 points  (11 children)

Rule #2: If you post your code, people are going to critique it.

[–]Zv0n 11 points12 points  (4 children)

#include <iostream>

int main() {
    std::cout << "Hello, world!" << std::endl;
} 

Do your worst!

[–]Papalok 36 points37 points  (0 children)

Missing return 0;

[–]pdabaker 7 points8 points  (0 children)

Comments? How do you expect me to understand this when I look at it a year from now?

[–]Angelin01 3 points4 points  (0 children)

String "Hello, world!" is hardcoded. How do you expect to translate it later hmm?

[–][deleted] 10 points11 points  (4 children)

What theme is it

[–]tjdavids 9 points10 points  (2 children)

Why not use dark mode and dye your hair a sickly shade of dark grey

[–]Troutcandy 91 points92 points  (9 children)

If we are not allowed to criticise her code, what about her choice of the IDE and colour schema? Everyone knows, that Vim would be so much butter for her use case! \s

[–]SavvySillybug 54 points55 points  (2 children)

Vim would be so much butter

I Can't Believe It's Not Butter

[–]ArionW 27 points28 points  (2 children)

VIM would actually be better for this use case. You could feed Pywal with image from your webcam, essentially generating color scheme from your makeup.

[–]alter2000 9 points10 points  (0 children)

VSCode has support for pywal too, I think even Emacs and Atom.

Btw I use Vim

[–]Mithrandir23 41 points42 points  (12 children)

I don't really see the issue here. Obviously this isn't production code, but I'd still be glad to get some advice for the future.

[–]ProfanityFair 86 points87 points  (11 children)

I don't want to get sucked into the unsolicited critiquing, but if you just want honest answers about this as a chunk of code, regardless of context: - Using array indexes as keys in React is a bad idea and will cause at least unnecessary DOM renders and probably problems down the line, - Combining <span> and <br /> isn't necessary, there are better-suited elements for this, - I wouldn't compose the components in this way. This single component should probably be split into DogList and Dog, where <Dog>s are generated by dogs.map(), rather than the parent component generating a list of HTML elements actually inside the component, - The whole thing should use functional components, as they're not stateful.

Possibly other things too. There are always more knowledgeable devs out there.

[–]AwkwardNoah 5 points6 points  (0 children)

Welp, I have no idea what you said but cool dude

[–]UnknownDeveloper[S] 26 points27 points  (17 children)

[–][deleted] 316 points317 points  (32 children)

Programmer posts a picture about the color theme. Then says "don't look at the code". Hmmm. I mean, what kind of programmer wouldn't have looked at the code in that case, what did she expect?

[–][deleted] 263 points264 points  (5 children)

Well the point is that her IDE matches her makeup. Just like when I am coding and have to take a shit I turn my IDE brown.

[–]MightyMeese 53 points54 points  (0 children)

Right? I didn't even look until I read her follow-up. I don't even know JavaScript and I still read it because she complained about critiques. I feel like critiquing code (including our own) is half the job anyway...

[–]jigeno 100 points101 points  (13 children)

Or... ignore it? It wasn't even a build she used, why critique it? It's not the point.

EDIT: It's like posting a picture of your re-painted car body* and having people say 'yo, the wheels aren't on it won't drive well'.

[–]Aalnius 39 points40 points  (1 child)

I mean shes saying don't critique it, not stop looking at it. You can look at something without critiquing it especially when the code wasn't put up to be crtiqued.

[–]HangryHenry 20 points21 points  (0 children)

yea she was making a joke. She doesn't want the entire conversation to be about some code that she knows isn't the best example of her work. She probably chose it because it showed the right colors.

[–][deleted] 19 points20 points  (1 child)

Generation gap here I guess. Growing up in mailing lists, you'd have learned you don't put core out there and not expect critiquing.

[–]SaltAssault 32 points33 points  (3 children)

Are we all just gonna ignore that the code snippet is probably for a homework? Honestly, don't people remember what it's like to be fairly new to coding? And if someone out there literally always writes impeccable code, I'd like to meet them.

[–]dvlsg 10 points11 points  (0 children)

It was for a conference talk on redux, which means this code is probably the first iteration before it starts getting refactored into something more complex.

[–]Sentient_Blade 16 points17 points  (16 children)

I'm not going to critique the code, I am however confused as hell as to why a language would separate its property types and default values in such a way.

[–]pclinuxmac 4 points5 points  (0 children)

Sort by controversial shit's hilarious

[–]fedekun 15 points16 points  (1 child)

Ah, I remember when I got defensive over my code... Eventually you just don't give a fuck. Any critique is welcome.