Frontpagify this code snippit and win a prize!
-
"It doesn't work!"
Accalia put down her coffee with a sigh. After a few weeks at Initech, she was getting used to this sort of bug report. It's understandable from a user but when it's the senior programmer who hired you, there should be a higher bar. Especially since it was his own code.
"What doesn't work, Mike?
"This code I wrote. It's based on your template, and I refactored it to use pre increment since you told us that post increment is considered harmful", said Mike, nervously tugging at his pointy hair.
now we're getting somewhere, thought Accalia. a few more hours of questioning and he might explain the actual problem.
"What doesn't work, Mike? Does it compile? Is there an error when running it?"
"Just come and take a look".
As Accalia walked over to her boss's undeserved corner office, she wondered just what abomination she would be greeted by, and also mused for the hundredth time exactly what Mike's relation was to the CEO that had allowed him to not only get hired but not be fired from the role.
"Here. I'm using the prefix like you said but it doesn't work. If you're going to bring in these coding standards you really should check them first.", said Mike, gesturing towards his screen.
And there it was, the worst code Accalia had ever seen, with a cursor blinking away happily, unaware of the horror it had just been a party to:
for (int i=0; i < 2*limit; ++i++) { //some code //about half way through short j = i/2; // more code using j this time, and some that uses j*2 }
Accalia stared at the screen for 30 seconds before wordlessly turning around, walking to her desk and opening up Microsoft Word. It was time to work on her resume.
-
Oh man, almost late with this.
Sometimes, it's the little things in life that bring us joy. For Jay it was putting his signature on a form confirming the decommission of their old, decrepit build server. It was slow, moody, and generally more trouble than it was worth.
"Three days," - he said to the machine, almost as if it were alive - "three days and you are gone."
There was work to do in those three days, however. The brand spanking new machine had to be set up and ready to take over.
Next morning, way ahead of the schedule, he was ready to run the build on the new server; all the tools and dependencies were installed, the automated build system was configured and everything seemed to have went better than expected. With glee, he let the build scripts loose on the server. The machine roared into life, running tests and building components...
... until it suddenly sputtered, coughed up an error, and stopped.
What in the hell... Jay thought, as he went to check the logs. All the tests passed! And this is the latest stable, no one committed to this branch in...
cplimp.cpp: In function ‘void getRecords()’: cplimp.cpp:1554:24: error: lvalue required as increment operand
Line 1554? What the... What the hell is
clpimp.cpp
?"Mark!" - Jay yelled across the office - "What in the blazes is
clpimp.cpp
?"Mark, who was with the company for more than anyone could remember, shot him a curious look.
"
clpimp.cpp
? I have no... Oh! Oh man, that thing is still in use?"
"It's in the repo. What is it?"
"It was a script used to import some data for a client from some ancient Clipper application. What about it?"
"It's failing to build."
"Open the file, let's see what the problem is... might be some old deprecated feature?Jay opened the file and jumped to the offending line.
for (int i=0; i < 2*limit; ++i++) { //some code //about half way through short j = i/2; // more code using j this time, and some that uses j*2 }
"What... the..."
"How did that ever compile? Better yet, how the hell did we never see the error until now?"
"Hell knows! - Mike scratched his head - "The code probably wasn't touched in years, so it was never rebuilt,make
might have been just skipping it. I mean, look, no tests or anything, and there are no earlier versions in git. It was probably all finished up before we even started using version control. But, hey, surely we don't need it any more... right?"Jay rang up the client. They were still in fact using the old application and were relying on weekly imports to Jay's application.
"We... We still need it..."
"Shit... well, guess it's time to try and fix it up? Maybe we can get it to build. There is no damned way we can rewrite it in two days."
"Who wrote it anyway?"
"Oh, he got fired years ago. Sorry, you'll have to do it, I guess."
"Figures... can't we just try moving the object files from old builds? It may work..."
"You can try, but I doubt it..."Jay tried. It didn't work. So he delved into the belly of the beast. After the whole day of untangling the mess in that one loop, he hopefully committed the changes and started the build.
cplimp.cpp: In function ‘void processRecords()’:
cplimp.cpp:3788:68: error: lvalue required as increment operand> Jay picked up his phone. >*"Who are you calling?"* - Mike asked. >*"The garbage handling company. The old server is staying for a while longer..."* Note: mostly written to see how it turns out, how badly I'll mangle the English language, and how many complaints I can get for making it too far fetched :P --- Filed under: [you have no idea how hard it was to get this thing formatted correctly](#), [we need a new markdown cloud to attack](#)
-
Oooh...nice flamebait.
I can't agree. Three days, no flames. Must be crummy flame bait.
-
It would totally be picked up on in a real front page article and end up derailing the comments.
-
And the polls are closed!
the judges will now begin deliberations....
-
And the polls are closed!
Sorry I missed out. I'll just have to make due with posting a Discotimebugwtf instead:
-
Jay rang up the client. They were still in fact using the old application and were relying on weekly imports to Jay's application.
TR . Repeat after me: Never ask the client whether they're using a feature, because they'll always answer yes, and will now be sure to call support if it turns out to be broken next release (even if it was broken in the last 5 releases).
-
Never ask the client whether they're using a feature, because they'll always answer yes, and will now be sure to call support if it turns out to be broken next release (even if it was broken in the last 5 releases).
QFFT
-
The Entries:
@anonymous234: https://what.thedailywtf.com/t/frontpagify-this-code-snippit-and-win-a-prize/51959/4?u=accalia
@LB_: https://what.thedailywtf.com/t/frontpagify-this-code-snippit-and-win-a-prize/51959/17?u=accalia
@Kuro: https://what.thedailywtf.com/t/frontpagify-this-code-snippit-and-win-a-prize/51959/21?u=accalia
@CoyneTheDup: https://what.thedailywtf.com/t/frontpagify-this-code-snippit-and-win-a-prize/51959/33?u=accalia
@Svieira: https://what.thedailywtf.com/t/frontpagify-this-code-snippit-and-win-a-prize/51959/38?u=accalia
@Jaloopa: https://what.thedailywtf.com/t/frontpagify-this-code-snippit-and-win-a-prize/51959/51?u=accalia
@Onyx: https://what.thedailywtf.com/t/frontpagify-this-code-snippit-and-win-a-prize/51959/52?u=accaliaThe deliberations are tense! there's talk about a mystery prize for another entry! there was a brief fist fight between two judges before the MPs arrested both of them, which coincidentally invalidates both their votes!
-
This post is deleted!
-
I got a comment that looks exactly like it was made in the article category. My work here is done.
-
there was a brief fist fight between two judges
-
before the MPs arrested both of them
Totally read that as Members of Parliament first, before I remembered you're left-pondian.
-
left-pondian.
Did you herar about the man who had the left side of his body cut off? [spoiler]He's all right now[/spoiler]
-
The bad joke thread is way.
-
-
-
Surely you jest. Obama assured me we were up to 57 States now, so we both know that the US annexed the useful parts of Canada and let Quebec and the Territories revert to barbarism.
Mostly, I got accalia and RaceProUK mixed up in my head at first.
-
Mostly, I got accalia and RaceProUK mixed up in my head at first.
wouldn't be the first time that happend.
won't be the last either i think.
-
7 posts were split to a new topic: Mentioning User ending with Underscore: FAIL
-
won't be the last either i think.
We might hope. @RaceProUK would be welcomed back into public activity with open arms (and some armour against the spines, of course; we're not fools).
-
We might hope. @RaceProUK would be welcomed back into public activity with open arms (and some armour against the spines, of course; we're not fools).
In the spirit of welcome, I do publicly pledge that, if @RaceProUK decides to become trans, I will refrain from murdering himher too much.
-
won't be the last either i think.
Well you don't have similar avatars anymore
@RaceProUK would be welcomed back into public activity with open arms (and some armour against the spines, of course; we're not fools)
If the sand has been cleaned out, sure.
-
After a long discussion and several fights that required police intervention to break up the votes are in.
ahem
With an honourable mention for pure chutzpah...... @anonymous234!
In second place with a hastily negotiated bounty of $10 for outstanding story telling.... @Jaloopa!
In first place, taking the full $40 bounty, for supurb wordplay and garnering a comment on his story worth of a proper front page article itself..... @Onyx!
Thank you all for participating! the submissions were very nice, and i was quite entertained reading them! it was very hard to actually determine winners!
I will be in touch with the winners via PM shortly to arrange delivery of their bounties.
-
and garnering a comment on his story worth of a proper front page article itself...
That happened after the deadline. CHEEEEEEEAAAAAAAT.
Filed under: I kid - that was the best, Also fuck you OSX, if I hold down E or A it's because I want lots of that letter, and not some popup to select alternative characters
-
That happened after the deadline. CHEEEEEEEAAAAAAAT.
the submission happened before the deadline, if i'm including comments on the submissions it's only fair that i extend the consideration past the deadline so that late submissions can still benefit!
also, it's my contest and my prize monies, so my rules!
and even without that comment @onyx's submission was clearly a contender!
-
Wow, so... ummm... that was unexpected. I just had this weird story rattling around and I just wrote it down for shits and giggles.
Thank you. And I hope you all had fun reading it, that's all I tried to accomplish, really. I'll try not to get an inflated ego now.
Filed under: Peasants!
-
I'd like to thank my job for being boring enough that I decided to fart out a story rather than doing anything useful after coming back from lunch, and @accalia for changing the rules after the submissions.
Also, fuck you @onyx for being better than me :)
-
Welp, congratulations to the winners of this contest.
Apparently the key to winning was entering very early and very late. This should probably be made more clear in the initial postFiled Under: jk, you guys did a good job
-
and @accalia for changing the rules after the submissions.
changing the rules?
Special prizes may be awarded to particular spectacular entries in addition to the grand prize.
-
Reading the rules is a to