Greentext your worst programming experience

Greentext your worst programming experience

Attached: 1_SKIAmwDYVnrMvFOopOCwPQ.png (881x473, 60K)

>be 15 years old
>decide to learn to program
>do so
>every day since

>take over web project from African developers to make some quick fixes
>everything is hardcoded and duplicated in several places
>things that should take 10 lines of code often reach 200+
>CPU running at 100% non-stop and loading a page takes close to a minute
I think that was one of the worst ones since last year.

Why not rewrite it?

>try programman
>too stupid to do thing
>to ashamed to ask

I rewrote things where required, it was a short project so didn't want to spend too much time cleaning up.

>get job
>get task to write enterprise-standard compliant server serializer
>do so
>works fine everywhere
>this one client keeps complaining about a bug
>spend a week looking for bug
>get nowhere, no way to reproduce
>boss insists its a bug in my code
>spend the next month meticulously going through each and every damn line of code in my program and in the countless external libs we use so maybe i could eventually figure out wtf is going wrong
>find a way to reproduce the bug, but it only works once in about 1000 tries
>spend another month trying to write software that reproduces the bug because it takes way too long to reproduce by hand
>boss insists this whole time it's all my fault and i wrote a bug somewhere and i should find it already
>finally figure out what the bug is
>turns out one very particular version of host environment we were running for the server had an internal bug, and my code happened to be using the api such that once in a blue moon a bug occured and it corrupted all user data
>couldnt debug it any further because it's all proprietary
>try to explain all this to my boss
>boss says i wrote a bug, can't fix it, and am dumbass
>ends up firing me after a week of bad looks
Programming sucks sometimes

>have to replace a guy
>script he have done took 7 hours to compile
>look deep into it
>he only use one or two where statement in his queries, fetch way too much data than what he should
>for loops everywhere, not a single while despite not having to browse all the data
>do that multiple time
>many useless operation
>various time the same for loop in the same function, but with one operation per for loop
I think he made something like ~100M loops in the end.
I modified the queries a little bit + how the data is handled. Script now runs in ~15 minutes and only loops 25k time

>cs course
>get put in groups with retards
>end up doing 95% of it
>have to pretend it was a team effort

What kind of third-world shithole do you live in where this is even remotely acceptable or legal?

WTF. This is almost as bad as pic related...

Attached: gZhmPr5.jpg (1795x709, 314K)

It was all perfectly legal

But we did do some other shady stuff that definitely wasn't legal, like decompile rival's source code and basically copy paste into our own product.

Lmao

>be employed as full time developer at fortune 100 company for 8 years now
>slowly realize the profession is terrible for ones health
>this is my life now
run as far and as fast as you can bros

I have a similar one
>cs course
>get put in group with a friend i actually kinda liked but couldn't code for shit
>i end up writing 105% of everything, additional 5% because i asked him to work on the easiest possible thing which was some text files with data that he could edit by hand and he even messed that up and i had to work all day to fix everything
>he got an A for the project as well
>mfw

Attached: Meme-Face-5.jpg (483x750, 19K)

I'd like two jobs, one picking trash or something outside and one as a programmer and switch between them in 2 week sprints.

>our team takes over a project from another team
>need to change functionality handled by this specific line

Attached: Screen Shot 2018-05-11 at 10.01.36 AM.png (1057x46, 21K)

I had to write some fucked up algorithm for graph theory in java. I half copied someone work and left it half unfished. Got an A on it because teacher doesnt know java and didnt even run them. Was stressful because it was my last semester and i needed the credit to graduate.

Honestly shouldn't take more than a couple minutes to parse and refactor.

>nightmare vision goggles

>7 hours to compile
*execute

noice. But can't you call the people who made the proprietary software and ask them to fix their shit ?

I think the problem was it was a version a few versions behind the current one and it wasn't supported. It was a long time ago, I don't really remember all the details. In fact I try to forget that episode as much as I can

>hang out at smug technology aficionado shitposting exchange server
>most of these dpg fuckheads literally cant even greentext

Us coders, huh? :^)

me irl for 27 years

>Greentext your worst programming experience
OK

Green

Make Green

Make Color Green

Set Color Green

set_green

color = green

WTF? Why does nothing ever work.

anyways:
Be me
Hear that programming is well paid
go to google
type how to programming
It's all stupid white males talking about ridicolously complicated shit
finally, find easyprogrammingforgirls.exe
download it
install it
it's still needlessly complicated
you have to type stuff to make to computer do things
lol, typing into your computer in 2018
its even sensible to typing errors
lol, no spellcheck in 2018
you have to remember all kinds of arcane "commands"
fuck that
also, now my ipad doesn't work anymore

>computer illiterate of my family
lmao, if it were me, i'll commit sudoku

you need to do
text_color = text_color.green

>newfag

> work with pajet
> constantly writing shit like: return (var == value)? true : false;
> void enableOrDisable(bool enable_or_disable)
> never comments anything
> copy and pastes the same logic multiple places
> try to explain how to write clear concise code fucks everything up anyway
> just rewrite it all
FML don't work with pajets

>return (var == value)? true : false;
That's hilarious

See, that's what Im talking about. Why do white men always have to make shit so complicated. Why not just
Green!
or something. If the computer is so smart, why cant it understand something so simple?

>test

My current situation:
>cs course
>me and my friend, both decent programmers
>he's a bit autistic when it comes to code style, but on the contrary I'm rather sloppy in this department so i was hoping to improve my style a bit in this project
>task is writing an AI for some game that should perform well in limited use alpha-beta pruning and min max optimization
>course is for 3 man groups, we are assigned a third one, let's call him 'retard'
>get first assignment, basicly implementing the game logic, friend and retard start coding in their branches some basic features
>clone friends branch since retards code was pretty much what I've implemented but cleaner
>friend has other stuff to do so i basicly continue to develope his branch
>retard hasn't done anything more than basic implementation, obviously we choose the improved branch i and my friend made
>retard says he's gonna do the last exercise which is just describing how our ai should work, when presenting he fucks up completely and just blabbers some bs
>new assignment, implementation of the network client and our heuristic algorithm we (retard) described
>my friend still has lots of stuff to do so i implement the whole client stuff myself as well as debugging it so it works accordingly
>retard shits out a 50 line of code heuristic in which 30 are empty or comments, 15 are just basic variable declarations and the rest are the actual logic

I've seen lots of people do something like this
if (someBoolean == true)
{
//do something
}

Attached: axe.jpg (600x450, 44K)

>be in university
>final project
>it's a group project
>teams of 3
>end up with a guy and a girl
>spend one day working on the project a week
>girl does almost nothing
I expected it might happen though so I planned in consideration and we managed to get everything that was needed done without spending more time than we should have.

>1
>2
>3 4

>new assignment at programming job
>inherit an Eclipse plugin written by Pajeets
>repo weighs 14 GB, and of course the first commit is called "import code"
>almost all of these 14GB are zipped up Eclipse installations that serve as build environments since what is CI
>In 4 windows/linux 32/64 bit flavours even though it's fucking java
>Also the repo contains an entire gcc 4.9 toolchain for compiling a separate C++ project in the repo that we split off to its own repo since then
>Half the actual plugin code is zipped up, so you can't just run Eclipse to develop, only the source code folder is unzipped
>Also, there are THREE source code folders, with one acting as base and the other two cp -r'd into base if you give an option to the build script because what are branches
>nonexistent .gitignore and build products in commits are not even worth mentioning
And I didn't even start talking about code yet.
>code duplication all over the place, I've seen 16 copies of basically the same class
>Java's NLS of all fucking things used to load code constants depending on the OS
>Strings all over the place
>Uses internals of other packages, or even copy pastes fucking Eclipse UI classes with minor adjustments
>its idea of run configuration for different targets is to overwrite ALL fucking compiler and linker options, fuck your customization
>reimplements image creation tool that used to be written in C with system() calls in Java and runs it not at build time, but at LAUNCH
>rolls its own implementation of DIRECTORY AND PATH SEPARATORS because fuck standard libraries
>nonexistent or excessive indentation not worth mentioning
>I've seen joining a list of strings through casting String(list).replace("[\[\],]", "")
>I've seen a proverbial fucking Runtime.getRuntime().freeMemory() as an attempt to free memory
I no longer love my job.

He also writes statements like
If (big && long&&
multiline && conditional) {
var = true;
} else {
var = false;
}

And despite discussing it in detail can't understand why it's completely redundant.
Today's code was a function with SIX boolean params and would be called as
foobar(true, true, false, true, false, false);

Sometimes that's actually in code guidelines. It's supposed to make things more readable. In some cases where you're comparing against many thins you may want to be explicit about comparing with booleans, and not relying on coercion or what have you.

What annoys me far more is this piece of brilliancy:
if (condition) {
return true;
}
else {
return false;
}

>almost all of these 14GB are zipped up Eclipse installations that serve as build environments since what is CI
Now that sounds truly horrifying

if( cond == true )
{
ret = true;
return ret;
}
else if( cond == false )
{
ret = false;
return ret;
}

Attached: 1214527513228.gif (260x146, 1.14M)

>CS course
>get put in group with literal retards(exchange students) from Africa and Asia in a lottery
>who does group project group assignment with a lottery?
>they don't answer emails, or show any interest in the project
>barely understand English
>massive project, and workload is calculated to be manageable with an entire group
>do everything myself since don't want to fail
>mention to the prof about my group
>says to just remove everyone else's name from the project and do what I can manage
>inform rest of my team through email of the changes to the group
>inbox full of pleads and begging a day later
>more begging before and after the next class
>ignore them
>mostly manage to finish the project
>get an A
>everyone else in group failed
I've also had to carry countless retards into getting an A due to the prof not allowing to drop them from the group even if they didn't contribute anything.

Only time I find this acceptable, and generally I would say refactor and change the variable name, is if the variable is poorly named.

if (redKey == true)...
I would read as "if red key is true" which makes a bit more sense than "if red key", however
if (hasRedKey)
Would read better. Yes this is a very contrived example can't think of a better one.

What school is this? Is this undergrad or graduate level stuff?

function retBooleanCheck(ret){
return ( ret ? true : false );
}
if( cond == true )
{
ret = true;
return retBooleanCheck(ret);
}
else if( cond == false )
{
ret = false;
return retBooleanCheck(ret);
}

Attached: realtek.png (331x260, 7K)

>went to an agricultural college which happened to offer software engineering
>surprise surprise, it's a shit time
>finish first year exams knowing I won't return to uni
>return to my home city and stay with my parents
>signed on for an internship programme earlier in the year, coming in to final stage
>placed in to groups of three
>myself, an indonesian student, and a weaboo of german heritage
>the three of us end up placed with a government department
>no space to accommodate interns in their headquarters
>end up at a station in the suburbs
>hour and a half commute
>paid an allowance, already under minimum wage, then spending a third of it on public transport
>didn't sign any paperwork
>effectively paid cash under the table, plus an HP Elitebook
>boss spends most of his time in city
>weaboo is the one reporting to boss
>hot as balls summer, AC was installed later
>eating shit food from parents and the local takeout place
>project is CMS + Cross Platform App
>i take charge of the app, end up working with Xamarin
>get a Macbook Pro so I can deploy to iOS
>Xamarin is a piece of shit
>end up ripping a MIT licensed example project off Github and plugging it in to the CMS
>hit that brick wall phase, and have no idea where to go for help
>shit coworkers, shit commute, shit environment, nonexistent mentoring
>literal swarm of bees outside our window
>eventually enrol at a different university
>party like a motherfucker when my internship finishes up

Upside: they never asked for the macbook back
Upside: the shitty experience did actually teach me a lot about project management
Downside: now I want to do CMS development with zero skills learnt

Attached: cwLegw7El-Y463MWMxQnNhQVu-PyJu7GCfTfGle3yvM.jpg (614x768, 91K)

Thankfully cleaning up retarded git repos is pretty easy. Just pull out whatever archives you need to move elsewhere, and filter-branch them out of the repo entirely.

enum {
ENUM_TRUE = 0,
ENUM_FALSE}
function retEnumCheck(ret){
return ( ret == ENUM_TRUE ? true : false );
}
if( cond == true )
{
ret = ENUM_TRUE;
return retEnumCheck(ret);
}
else if( cond == false )
{
ret = ENUM_FALSE;
return retEnumCheck(ret);
}

>africa and asia
god damn it dude. You had great prof. Normally this end with :
>stop with your colonial white privilege and do stuff for them

>3rd year of university
>big project
>have to build robot with people from electrical engineering
>3 software engineers
>have to write the software for the robot
>do the computer vision part since it looks like the most difficult and most interesting part
>it's just shape detection with a webcam
>do simple shit with openCV
>ends up working perfectly with not that much work
>meanwhile there's a try hard idiot in my team
>spends weeks implementing what should be a simple path finding system
>essentially there's some obstacles on a map that's given to the robot and it needs to avoid them
>of course the idiot didn't do it the simple way, he did it the try hard way
>his way of doing pathfinding means he needed to write code to handle each possible case of obstacle positions
>code for when obstacle is there
>code for when there's two obstacles
>code for when there's 3 obstacles
>code for when obstacle 1 is near X position and obstacle 2 is near Y position
>What the Fuck.mkv
>Tell him his way of doing pathfinding is dumb and say he should just convert the map to a grid and then use an algorithm like A*
>fucking idiot complains to the teachers that I don't work as much as him on the project
>show them what I did and get off with a: "everything is fine but try to be more present"
>final presentation arrives
>show off our robot to the teachers
>robot is booted up
>robot goes straight for the obstacle and hits it

I hate tryhards, they are much much worst than people who do nothing. At least people who do nothing don't sabotage the project with their fucking garbage shit code.

>be me, small fry webshitter in small web-studio in literal shithole
>had to make changes to one old webshop made with one shitty ecommerce platform popular in my country
>templates literally duplicated 8 times for different pages with almost no difference
>8 times for each categories, category, products, product
>JS and CSS are also duplicated since most of it was hardcoded into templates
I made it workable in browser despite multiple errors in console, reported and left that job 4 months later.

Okay, here I go:
> Be me
> Start working as IT supp for a small company 4 months before going to uni
> I did everything from networking to coding and repairs, with shit salary
> Still learned a shitton because I know how to google for good info sources and docs
> Start uni but still have to work because I don't live off welfare also my parents are old
> Get constantly grossed out by "chads" and community assistants that can't code for shit 7 semesters in, they just pass because they do community work
> Everyone uses netbeans, java and vs 2012
> Nobody writes comments, adheres to code conventions or reviews their code
> I end up doing all the teamwork by myself because my code was the difference between a 100/100 and a 60/100
> Now work at a small dev company doing only coding
> Usually attend professional courses and training sessions paid for by my company and some even myself
> 8 semesters in I get expelled for failing the diff. equations course 3 times because only shit-tier old-ass teachers lecture it, howework is 40% of the grade and I can't be fucking bothered to do 100 homework problems every period and a small project (I always turned the projects in, but almost never the homework problems)
> Mfw I now work part time dev and part time do freelancing
> Mfw still get good cash doing homework projects for my ex-peers
> Mfw I only lost 3+ years of my life in a low-tier school doing nothing except realising the absolute shit state of my country's education system, putting up with pseudo-chads and retards
> Mfw all I now know is thanks to my company and myself

Attached: photo_2018-05-11_11-32-25.jpg (694x801, 39K)

> Mfw I only lost 3+ years of my life in a low-tier school doing nothing except realising the absolute shit state of my country's education system, putting up with pseudo-chads and retards
This is why I hate it when people say the ranking of your school doesn't matter. Like the number doesn't matter but it's indicative of the quality, rigor and depth that you go into during course.

I don't care about reputation but about curriculum. Unfortunately high ranking/reputation is correlated with a good, solid curriculum

>cs course
>get put in groups with tryhard autists
>end up doing 5% of it
>get to pretend it was a team effort

Attached: 1503011597902.gif (200x279, 993K)

>IM THE BEST PROGRAMMER EVER
>fails the class

lol okay

>Mfw all I now know is thanks to my company and myself

That's how schools fucking work. They make you learn the absolute fucking basics so that you can keep learning yourself. You'll learn more in your first 2-3 months at a job than you'll learn over 3 years in uni.

And the funny part is that you flunked yet still think you are good.

>some guy have to convert xlsx to csv in a Unix system so he can import them in some some db
>Tell bim to use whatever script je find and do the job (Bash, perl...)
>Manager tells him to create a java program
I thought it was a meme

>> constantly writing shit like: return (var == value)? true : false;
What is wrong with that?

Your school doesn't have self-evaluations?
At the end of each semester, you get to lay out who did fuck all, so in the end your grade can go up or down depending on if you did anything

>back in final year of uni
>knew java, c, c++, from previous classes
>professor puts us in teams of three and gives us a semester long ruby on rails project and fucks off, not to be seen again till projects are due
>i couldn't figure shit out
>was completely useless
>"pls let me get credit what can i do let me do anything pls"
>they let me do all the content/styling and write all the test
>they put down that i did my equal part in their reports
>get an A
>Am now employed as developer for AT&T

Life turned out pretty ok

same result with:
return var == value;

Oh. Yeah I guess it's dumb.

>fails the same course 3 times, expelled
I see nothing wrong here. There course was there to weed out brainlets, which it did and you were too fucking dumb or stubborn to switch degree paths after failing not once, but twice.

>straight out of uni
>replacing a engineer
>the remaining engineers are located on a different site in a different city
>stuck alone as a junior straight of uni
>boss expects me to be senior level
>have to make senior/chief decisions all the time
>still get paid junior wages
>get called into random meetings 1-3 hours ahead of the meeting
>a completely new technology gets mentioned
>"user, you're the expert. Can you tell us more about it, and the benefits/negatives of it?"

If I wasn't an extremely quick learner I'd be completely fucked. I can't believed they put a junior in this situation to begin with, I've been close to quitting so many times.

IT is fine if you have a good environment. Luckily I got my relocation approved, else I'd fucking quit. What the fuck is a company thinking making a junior sit all by himself with no support or training. It's a fucking miracle that I haven't completely fucked a system up.

gonna shot one who wrote that shit

Attached: 1525902446183.png (392x278, 138K)

FUCK THIS STORY IT MAKES ME SO MAD

What the fuck is that

>the year is like 2000
>hey whiz kid, can you cook up a quick and dirty debug UI that reads a few parameters over RS-232

>nearly two decades later
>same thing is now commercial software with tons of parameters in a database, various logic and report generation
>code is a pile of crap due to massive amount of scope creep and retarded customer demands
>and it's still in delphi

on the bright side, maintaining this piece of shit still brings in some money

Attached: sdM7KKf.png (684x300, 13K)

REELDEG :DDDD

you'll be surprised many people wrote code like this:

>return (var == value)? true : false;
Why is that bad? If var isnt a boolean thats completely valid right.
bool isfive(int x) { return (x == 5) ? true : false; }
int y = 5;
if (isfive(y)) { // something }

Note that the example is too simple but you could replace isfive(int) with any function thats many lines long

...

nevermind you were aiming at
retrurn x == 5;

>prgram
>it noes work

we are talking about boolean here

t. javascript faggot

Attached: 1463730178882.jpg (218x330, 9K)

you should narc, that'd show your cunt boss

>ERP system written in C#
>winforms
>user auth done on client side
>excel integration, if you don't have the exact version it doesn't build, everyone just keeps replacing it reference and commiting it, has to be done after every update
>vs2008
>writing SQL manually
>complete lack of polymorphism, functions full of 'is' operators
>no real project architecture, ton of code duplication, changing something fundamental means changing it in 10ish places
>X and RealX variables all over the place, zero documentation
>no multithreading, everything done on the main thread
>manual XML generation

i hate javascript, faggot

Attached: 1513696003822.jpg (236x326, 18K)

I just started to learn how to program and I have no idea what all those scary words mean

There's literally nothing wrong with this. It improves readability.

but i think it's like 2 more assembly instructions (one more cmp and jump?) which heavily degrade performance

>heavily
Unless you're writing a real time ray-tracer there's no reason to be that concerned about performance.

well for starters, "ERP" is a term for erotic role-play

desu it should be optimized away by any modern compiler
not that its good practice to rely on that kind of thing imo
i guess worst case would be like
cmp xl, 1
instead of
test xxx, xxx
i think

This story is so fucking fake.

I've seen
if (data == null) {
return null;
}
return data;

If you write code that solves a business problem, your boss will never ask you what language you wrote it in. The manager probably knows that everyone there has java on their resume, and wanted to suggest something that he knows can be maintained after that guy leaves, even though it's completely the wrong choice, the manager doesn't know that.

>pic
Sensible chuckle

the new way is
color_of_text += .greem.color.of.text

>oldfag

Here's like 90% of mine
>Some typo breaks my script and causes a million compiler errors making it hard to find the typo and fix it

Do your variables differ by one letter?

Wew lad. Are you in Austin? That sounds exactly like what I ran into with an *ahem* certain company. I put in my two weeks after I got the size of the fail there. I couldn't tie my career up with that kind of shit-sweeping.

>greem

First post most painful post

Attached: 1519966675636.gif (450x255, 2M)

No, but I'm thinking about leaving once my contract ends in November. Local management is great, but retarded uppers shoved their massive shitpile of code onto us and expect us to maintain a legacy branch of this shit while we're trying to dig ourselves out of it. I'm going to get a couple more people to help out with it, but I don't think fixing shit like this helps my resume.

>cs course
>choose group, seek out fellow autists
>in a group of 8, end up doing 12.5% of it
>don't need to pretend it was a team effort

Attached: 1525016184651.png (1024x635, 944K)

I had a pajeet in your position once
I wish I could have done the same, in the end I gave him the task of writing the two-page doc/report, I sat with him while he wrote it, ended up rewriting 80% later in the evening
Fuck pajeets. You may have been useless but at least you weren't pajeet tier