GIGA1OO1
230958
4888
271
*All Memes Were Stolen
FP Edit: Thanks so much it makes me happy that people like my nerd humor :).
Send Solutions To P=NP, or P!=NP
Cheomesh
#7 That's how you get shitcanned.
Flames99Fuse
#5 Are you only 5 lines of code in or what? Nothing ever compiles on the first try, it's like a USB cable.
HauldrenCollider
The MATLAB one should have actually been LAPACK under the hood
GlazedHamRiot
#2 purina tests animal food on animals? Thise savages!
Idontknowwatiexpected
thelastcoolbrandon
Why do we hate Matlab now?
Neogreenyew
#22 O(n) is correct for a traversal. No way to visit every node without it being O(n). Searches and inserts are guaranteed O(log(n)) though.
chrishallett83
If you don't comment and document your code, you are a shit developer. I don't care if you write 1,000 lines of perfect code per day. U=SHIT
KingORedLions
The 'j' is Dijkstra isn't silent because in Dutch, 'ij' is a digraph that largely replaced the letter 'ÿ'. True story.
GiantMechanic
It took me a while to realize that the (4) didn't mean there were 4 images.
ThereAreSomeWhoCallMeeeTim
I'm only 6'3" but I got that last 2" where it counts baby.
zecko1916
Don't shit on MATLAB. It's an extremely powerful tool used in signal analysis, pattern recognition, and control systems
PangolinRex
I have never seen worse documentation. At least Octave isn't a straight up cash grab
DoesAnyoneEvenScrewBearsAnymore
Scientist here. We use Matlab at a Fortune 500 company for least squares regression of spectral data libraries for analysis. Super helpful.
danishjuggler21
These dumps always leave me convinced that there are a lot of terrible programmers out there.
DarthFutuza
This one screams CS Sophmore
Jbone0010
I must be out of the loop. I like Matlab for dsp and data visualization.
zma123456
Most of these were lame only one or two were funny or clever.
c0dengo
#22 ok you'll have to explain this one because traversal means "visit every element" if you're done after O(log N) then you've skipped some
WhyAreAllTheBloodyUsernamesTaken
This deserves to be the top comment +1
c0dengo
Binary tree lookups for an element will be O(log N)...
SchwarzGeist
Yes, balanced BSTs take Ο(log) to find an element, but we're talking about traversals.
HPCmonkey
yep, enumerating all items in a BST is O(n).
Madredeux
MATLAB is actually super useful so idk who made this dump
shepahrdjhon
Useful but indexing is annoying.
AnythingMuchShorter
Also no mention of C++ because newbs think it's dead.
DarthFutuza
*laughs from the Unreal 4 Github*
GIGA1OO1
I made it
TobySomething
RunescapeFisher
Thank you for making it :) I found it hilarous
GIGA1OO1
They we're all stolen, but I'm glad I could make you smile!
Meltemi
#24 That beautiful bogosort.
Zechie
It's the best*! (with one in a million odds)
DarthFutuza
Zechie
0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 22, 24, 26, 28, 30, 32, 34, 36, 38, 40... Am I doing it right?
DarthFutuza
Oh hey look at that, it sorted them!
Zechie
Oh wow! I must be lucky!
Ttarler
Ah kid, the real world is gonna break you
GIGA1OO1
I'd like to see it try, I've been dead for a long time.
ILoveGiantBananasForScale
I understand these, but as a Network Engineer I wish people took the time to express their suffering in memes in the networking world.
khora
Oh, one write on a socket doesn't translate into one read from a socket? But Napster did that!
dietderpsy
No time, must troubleshoot.
shakeedKeebler
There was that meme about a spanning tree
Dogmeat15
I️ have to learn python for a new job or at least grasp the basics, any recommendations for resources to use?
nihilityfarce
https://www.edx.org/course/introduction-computer-science-mitx-6-00-1x-11?utm_source=OCW&utm_medium=CHP&utm_campaign=OCW
Steps1000
https://www.learnpython.org/
DarthFutuza
I really like Learn Python the Hard Way, but...it's 2.7 from what I remember so you should find something newer - 2.7 is becoming outdated.
FactCheckerExtraordinaire
I recommend sentdex on YouTube. But it's a very easy, very popular language, you should have no trouble.
Mergul
You can try Dive Into Python by Pilgrim if you want a book.
terrorfield
What else would Purina test on? I don't understand!
Magpiebones
The way they test matters. Purina/Pedigree etc shit-companies vivisect their dogs and cats regularly to see how their products affect 'em.
malikcarr
I suspect this is a PETA-grade sign, if not actually made by them specifically. You know how those people are...
Vulspyr
For those who don't know Matlab is the fifth most dreaded language to use according to the stackoverflow 2017 developer survey 1/?
Vulspyr
(https://insights.stackoverflow.com/survey/2017#most-loved-dreaded-and-wanted) I've had to use it in school and I'm pretty sure my 2/?
ffgkrwcqrq
A grad student I knew was finding the 2-d confidence limits of a 13-variable function using MatLab, by randomly jiggling each variable until
ffgkrwcqrq
it triggered the confidence threshold. Each data point was taking hours to map out. His solution was to run a bunch of MatLab instances
ffgkrwcqrq
in parallel on the supercomputer. I was, apparently, the only person to think this was a bad idea.
Vulspyr
I would agree with your assessment.
Vulspyr
dead grandmother can compile a basic function faster. I talked to a TA and he said that ran a simulation in Matlab and it took 2 hours, 3/?
Vulspyr
he ran the EXACT SAME simulation in Python and it took 1 minute. Matlab is an awful abomination that 4/?
Vulspyr
diserves to die a slow painful death alongside the person who made it. 5/5
coolcalx
Matlab doesn’t compile... And if his code was that slow, he probably used for loops instead of vectorization.
Derodric
My professor claims writing comments to document your code makes you a shitty programmer. -Proceeds to not understand his code in lecture.-
ChallengerDeep
Programmers need to learn how to type. Should be a required part of the curriculum. So useful for everything. Commenting becomes much easier
SchwarzGeist
Depends on your coding style. If you keep your functions short and well documented, you'll rarely need to explain specific lines of code.
dietderpsy
It depends on how big your code is, for a big program you need a proper document.
HPCmonkey
By comparison, I start major projects with a huge comment block explaining what I want to do and how I plan to do it. 1/2
HPCmonkey
Then reference that explanation in more detail with each function or complicated line. Not the most efficient, but simple to maintain. 2/2
tpgreyknight
You are gonna love the "Cleanroom" methodology
HPCmonkey
I don't work on anything particularly huge, so it works for me. I think my largest project was only around 10K lines excluding comments.
equityforpunks
This must be dump of CS student. You'll be surprised how often you'll need to write sorting algo in actual job: likely once, in interview.
kenkennethfromconnecticut
Thank you for this. Yes let’s be best at rewriting code!
gnuclear
Maybe there'll be a guy who writes one once, sticks it into a library, then imports that library in the future, and forgets how it works.
TumAgain
Came here to type almost this exactly.
Ultratoxic
I'm glad I paid 45k to get most of these jokes
perey
An accountant will never need to add up a column of figures by hand, but it's nice to know they've passed that skill gate.
Zeroji
The only times I've written sorts were on really reduced platforms, standard languages always have solutions faster than yours
jenniferlawrenceisabear
I was thinking this. In my experience such reinventing of the wheel has been rare. abstraction, abstraction everywhere!
PeterNormal
but sooo many comparators to use other people's sorting algorithms.
jsievers
I unfortunately may have to write one, to speed up adding randomly arranged data into an array. Only has to make cache happy.
RationalRants
I've never had to actually implement one, I just had to prove that I understood the time complexity and could pick the appropriate algorithm
Dylzner
Ya like somehow the add remove on lists isn't good enough and also probably out of your scope for your actual programing job unless ur Intel
Slander7
I just started a job with a lot of coding, and for the most part: getting it done correctly, quickly >>>>>>>>>>> getting it done elegantly.
Gotbread
std::sort() for most cases. Some handwritten trickery for gpus. No reinventing in actual code.
Gotbread
However it helps to understand the complexity of them and if they are stable
jrntn
After ten years of working in the industry, I can report having written sorting algorithms zero times.
PickIeRick
Right, 99% of the time you can just use a sort from an existing library. No need to reinvent the wheel, as they say.
MrCaptainPancakes
Agreed. I recognize the references... But I don't find them applicable in any of my post-school experiences.
DarthFutuza
Why rewrite the std library when std::sort works just fine?
onychomys
I write my sorting algorithms by doing the smart thing and calling list.sort(), because the compiler is smarter than I am.
ImAfraidYoureAllPsychosSoIMadeThisAccount
Right. No need to reinvent the wheel.
jrntn
That's the thing. Sorting is a solved problem.
doctormellow
Most of our sorting is via SQL (ORDER BY), I had to sort one of our logs that we audit, but it wasn't sorting, it was more like... 1/2
doctormellow
Find the log where the user logs in, and logs out, and associate every action in between to that user.. I didnt develop the log func (2/2)
DarkSock
JikaelMackson
Lmoo
KeeleonOhms
I know enough about coding to know these are funny, but not enough to know why.
neutronfish
This is undergrad CS minutiae that a handful of people actually work with in their professional lives.
DarkSock
I peed in a horse once.
boozel
O(n) notation looks impressive, though! I KNOW MY SORTS! RED-BLACK TREE! RESPECT MEEEEEEEEEEE I’M SMRT BAZINGO
neutronfish
You just need to be able to tell if an algorithm is O(n) or O(n^x) and if you can modify it to be as close to O(n) or O(log n) as possible.
WellThatsOriginal
TIL nothing from this dump.
AllTheOtherNamesWereTaken1234567
I learned that one guy is 6'5"
WellThatsOriginal
Its all I understood from the whole dump
HugeFootJob
Hey now, how's matlab trash?
DarthFutuza
Because it isn't opensource/open standard and requires an expensive license to use.
SomeDetroitGuy
Too many people can't do functional programming.
pilojo
Because it's shit unless you're working in machines with severe hardware limitations. Even then, procedural is better sometimes.
khora
Why is hardware an issue here? After all, byte code is procedural.
pilojo
It causes a lot of overhead
khora
We solved that by making support for jumps and return in CPUs.
khora
Too many people actually do functional programming.
HauldrenCollider
It should have actually just been LAPACK under the hood. But I agree it sucks :p
MrPeebles
In addition to this, because it's not a "prioritized" program, so most people don't really teach it, so it's just a headache to work with.
begentleimnewhere
starts at index 1... doesn't make a big deal to me but some ppl like to cry
RiddlingVenus0
Whenever I have to use Matlab for school this always fucks me up because I'm used to the first index being 0.
GIGA1OO1
Its not made for coders to code on, it's made for math majors to code on. So it doesn't follow normal coding conventions.
shepahrdjhon
Sure but do you really want to piss off Andrew Ng
eeyrjmr
Completely. Takes me 5min to switch to MATLAB code thinking
wuzzyvear
MATLAB, GNU OCTAVE, etc are great if you spend hours generating a theory on paper and need to quickly have the pc do the heavy lifting.
wuzzyvear
Speaking as a non-programmer of course.
eeyrjmr
I agree, I am using it right now 4 loop stability checks. That doesn't refute the style of the script is rubbish & I am a hardware engineer
Ben10inSpace
Hey how did u learn to code? I’m interested in trying to learn but don’t know where to begin
MrPeebles
Quite a few free/inexpensive code sites out there. I use datacamp, but:
GIGA1OO1
I started in high school and am currently in college, I'd recommend reading building Java programs 4th edition. It's a textbook but a good 1
Ben10inSpace
Thank you
MrPeebles
https://learntocodewith.me/posts/code-for-free/
Ben10inSpace
Thank you, srry just saw this
MrPeebles
No prob
RiddlingVenus0
Most people either teach themselves or take classes in high school/college.
Ben10inSpace
Thank you
maniacalmacaroni
#1 if you're 6'5", you can code on a Lite-Brite; it doesn't matter.
NZerow
I'm 6'5 and I write in vba. One of these features is what keeps me interesting
mybrothersmario
I'm 6'7" it does not matter....
mybrothersmario
I mean my height, not coding on a Lite-Brite, just thought I should clear that up.
Dylzner
But if you can't sort you'll take too long to give her a big O.
perey
Searching for constant big O.
doctormellow
So.. Big O (n)? ;D
ImgurCelebrity
and what's wrong with Visual Basic!?
HPCmonkey
The funny answer is everything, but if you never have to run on anything other than windows machines then ¯\_(ツ)_/¯
ImgurCelebrity
VB or VB.Net? VB .Net is a CLR-targeted language which, with the open-sourcing of .Net, will run on any device you please.
hassanshihabkarim19350
It's a good learning code for kids but its not really useful because it can only be used to create simple applications for windows.
ImgurCelebrity
You definitely don't know what you're talking about.
hassanshihabkarim19350
You were right, it's been a while but I now actually use it at work
hakunamatatas
I'm 6'5" and a coder, I wish women loved me as much as people on the internet think they should.
Bob570
Lol, imgur seems to think being tall actually helps you get women. For me it just means I can't fit into a lot of the cars I want to own.
YouAreKillingMeSmalls
I know what you mean. I'm 6'5" as well with a good job as an electrician. Height itself hasn't really done that much for me with the ladies
hakunamatatas
Yeah, though the taller women I've been with (~5'10") do seem to appreciate it.
chrisharddick
Maybe you’re just ugly
YouAreKillingMeSmalls
Oh snap! Haha! I didn't say I didn't have luck with the ladies, just that height alone hasn't seemed to make a difference
Sprixxen
Considering height and $ are in the top 3 of what women look for, have you considered growing a beard perhaps?
AlkeneThiol
Yeah try being below average height for a year. Then tell me your height makes no difference. Fuck. You.
YouAreKillingMeSmalls
Fair enough. I was thinking more my height vs average height, and how there didn't seem to be a noticeable difference...
thetacosavior
Even if there is no documentation, text notes in the code is super helpful ------dont remove this because shit will break-----
FurtiveGlancer
Yes, @OP, where's the doco for this dump?
khora
Treat names and types as documentation. int foo(void *o)
Gezo
Clean Code dictates that the code should describe itself. Little to no comments needed. That's different than documentation.
splain
Please comment your code. Even self-describing variables don't explain why that code block is needed in the first place, what it returns etc
PepsiFluxX
My linr of thinking on this subject as well. Can get into long disagreements with my best friend over it tho.
yuugian
/* Beyond here there be dragons */ /* I am very sorry about the following regex, please don't tell QA */ /* Spares -> ;;;;;; ;;;;; ;; */
ratchet3789
//I Have no idea what this does and why I called it "WhyWontYouFuckingWork"
Spiderbubble
//No idea why this line is required, but it is
ATLandNerdy
The most infuriating I've come across is "It's self documenting code" and then they go out of the way to make it as obfuscated as they can.
razetherunner
i may barely remember the little bit of C++ i had to take, but COMMENT FUCKING EVERYTHING was rule #1.
Trisar
// I'm just fixing what the last guy broke when he fixed what the guy before HIM broke. I have no idea what 85% of this does.
rhilterbrant
# I dont fully understand how this works. I grabbed it from [site], and it works as described.
ImOPsMom
Unless the comments don't age well and fall out of sync with what the code actually does :D
Cassiraa
//I DON'T KNOW WHY THIS WORKS BUT DO NOT REMOVE
iamawaffleiron
// hard coded array, do not remove unless planning to kill yourself
ATLandNerdy
//This works and I don't know why. If you try to fix this code, increment following counter as a warning to the next coder that tries: 12
splain
I'm going to use this! Or possibly //number of times I've reverted this code after someone thought they "fixed" it and broke all my tests: 9
ATLandNerdy
I don't know where I saw it, I didn't come up with it, but i literally LOLed when I read it the first time.
YouLostTheGameAgain
While I never had to keep any documentation (still student) I do like to comment every few blocks of code and important lines.
splain
Bless you. Never lose that.
ratchet3789
It's as simple as writing a comment above every function and confusingly named variables.
MidnightRising
I was in charge of translating a piece of Java code over to Javascript. It had tons of math and was entirely undocumented. I didn't (0/1)
MidnightRising
know what it did, I was just in charge of translating it. There was one comment that I put in: //good luck
InsolventTacos
I once wrote at the top of a file: BEWARE ALL WHO ENTER BEYOND
woopwooppulloverdatasstoofat
i've done that for myself before to know where things are particularly fucky. "#BEWARE: TURN BACK NOW!" etc
khora
At that point you should look for a cross compiler and put all the crap in a black box.
MidnightRising
Due to certain project requirements that is not allowed for security's sake. I also didn't think of doing that.
ArdentSlacker
Can depend on the contract and what chance there is of being caught. If it's $5M for being late but $5 for ignoring security reqs... :D
khora
You can write your own cross compiler.
GIGA1OO1
Documentation is a miracle time saver, but a pain to write.
dakhath
It might not seem like a time saver at the time, but when you come back to something three years later it sure is.
[deleted]
[deleted]
vneoaivin
A little of each. Understanding code without documentation is a skill you'll need, and if you hate it enough maybe you'll fix that problem.
tomyironmane
I write it cos otherwise I'll forget what the fuck the code is supposed to do, and I kinda suck at code.
JohnWickWithHisPencil
Amen
Dingus2
You're fired.
Rakugabi
Updating 10y old undocumented code : "Let's see what this part does". 2 days later : "Wait a min, it actually doesn't do shit ?!"
vneoaivin
And now you have to justify to your incompetent project manager (but I repeat myself) why you spent 2 days on code that doesn't do anything.
javer80
That's why technical writers exist
Cheomesh
I was never a great coder, but damn could I document what the fuck was going through my head that lead to it
maverickmarq
A list of dictionaries is usually a dictHolder. Never fails to make me laugh
Phatplat
Needed by test though
Iankill
Actuall documentation "I've read i named the encryption function the encryptkeeper because it made me laugh"
TheNewAndImprovedUser
"If you adjust this module, you deserve what you get"
Tarelgeth
Once we ran into a function call named "cornedbeef" and it took weeks before anyone could figure out exactly what the hash terms were.
brassknucklenerd
I use mindmaps when planning features, and each branc terminates with a test statement. The test statements are used for TDD. The doc is >>
brassknucklenerd
<< generated by the process, with no gaps.
brassknucklenerd
*branch! Frig!
AVoiceOfReason
You can save time in documentation by writing self explanatory code. The .NET team in C# is very good about highly descriptive method (1)
AVoiceOfReason
and property names, and honestly other communities should learn from it. Save comments for low level stuff that can be hard to follow (2)
AVoiceOfReason
such as crazy unsafe code, pointers, memory allocation, and so forth. Or shenanigans about the OS.
AVoiceOfReason
You should write code in a way that's self descriptive. Read Clean Code by Robert Martin. Well readable code, self descriptive variables, >
AVoiceOfReason
and code that follows proper guidelines. Don't use go-tos, refactor. Don't use regex to parse HTML, use an HTML parser. If you do this, >
AVoiceOfReason
you won't need comments and you won't ever have to worry about silly stereotypes like your code breaking if you sneeze.
splain
Comments aren't just to explain what the code does, they're also for why, how to use, etc. Comment yr code, even if you think it's readable.
AVoiceOfReason
All of those things can be self explanatory. Save it for asm, c, or c++ and for low level implementations. Clean Code is a good book on why.
HPCmonkey
As somebody who has had to troubleshoot "clean code" out in the field, fuck you and the shit horse you rode in on. Document your shit.
AVoiceOfReason
It wasn't clean enough if you had trouble. And documentation doesn't necessarily need to be in code comments. It can be in a spec document.
AVoiceOfReason
If your method is called GetEmployees() instead of E () then the comment //Gets the employees becomes immediately superfluous. I highly (1)