Seen in some source code...
"If we reach here then the ladies bits are pointing skyward"
Thank goodness for code reviews. However things weren't always so squeaky clean as one Register reader discovered while attempting to sort another's sweary source. Welcome to Who, Me? This morning's story comes from a reader we shall call "Philip" (for it is not his name) and takes us to the 1990s when he was working for a …
I guess we all have done this and that I am not an outlier? Please? Or maybe at least 90% of commentards?
Not in any project that others would see, thank the maker. I do have some expletives in my source code, but milder forms. Plus some court has actually declared that swearing in dialect is not deemed (too) offensive.
Never did it - I got past finding offensive words "funny" before ten, I guess. Probably because I was exposed to good humor that doesn't need them.
Writing software for me was and is also a show of skills and elegance - not a show of how much childish I could be. But maybe I'm the outlier.
"It does not mean that the stress relief becomes part of the code base"
Except it does. Or rather, from my perspective it sure seems to. I've seen it in every single large coding project I've ever worked on.
"(or anything else that will outlive the current state of affairs),"
And again, but it does. A single word or phrase uttered at the (in)appropriate moment will often send the aware listener(s) into gales of (sometimes stifled) laughter. The more solemn the moment, the more pronounced the effect. I once watched two members of a C-suite almost lose it completely as the Boss was reading carefully worded excerpts from the annual report ...
"the stress relief becomes part of the code base"
I don't swear in source code. But that sure as hell won't prevent me from dropping in comments to explain that something that was being done in an illogical manner was because following the spec was mandatory even when the spec was not only wrong but created by an entity best described as "something that tumbled from the cloaca of a kittiwake".
Keep it classy and keep it interesting. No shit feck and arse.
I don't do that either. The reason being that I couldn't ever recall what **** is supposed to hold, or what ******(***, *******) is going to do. Respect to Brad that he could do it.
Swearing at my sources... well, that's a whole other thing.
One place I worked at early on insisted that we have a file of "names" and "functions". Usually written in Word or some such. You could call a function something mundane like "Bob" or whatever you wanted, Luckily, the cross-reference defined the more obscure/obscene names.
That is also true, and worth keeping in mind. However it's also worth noting that some people may find it slightly amusing to have certain notes read out in as dead pan a voice as possible while absolutely everyone else is trying not to laugh. I know of judges who failed to keep their laughter in...
Try a high pressure job where even notes could be read out in court. That will ensure things are kept at a formal level.
Sadly this results in comments not being kept in the notes that it would have been better to have kept. Notes are so often censored (self-censored) and this results in their not being complete.
I don't think I ever knew anyone who reached for the resus kit without swearing at least under their breath.
I've told this story before, but it's relevant..
I used to keep a simple text file on my work laptop where I noted down what I was doing in site visits, so that on return to the office I could enter the relevant information into the timesheet database... (This was turn of the century, and we'd not yet got any dial-in or vpn to our own systems, though we'd dial out into clients if we could.) Because of the often whimsical nature of some of the tasks I was given, my notes often had some fairly fruity opinions of my boss included, or other non-work related comments. Obviously, when transferred to the timesheets, these thoughts were skipped.
There came a time when I was out of the office for a good couple of weeks solid, and with month-end coming up, I was asked for the details of my time so someone else could enter it onto the system. Of course it was vitally urgent, so I quickly copied the relevant bits into an email to the office, but somehow missed sanitising one of my opinions of my boss for a particularly pointless task I'd been given. (It involved my wasting half a day and best part of a 150 mile round trip collecting about £5 worth of washing his son had left behind somewhere.) For this I got called into his office and was told "it's about time you started looking for another job." So, I went home, and did. After I'd spoken to a solicitor who jumped at the opportunity to discuss "wrongful dismissal" with them! (They caved, of course, and paid me the equivalent of several months wages in recompense.)
Obviously he was a dick for both sending me out on such a job in the first place, and for reacting so badly afterwards. I was not sad to leave, but it's taught me that even in "private" notes, I should be a bit more diplomatic...
A quick look at your previous comments suggests that your superior and advanced sense of humour appears to consist of referring to the Irish as Leprechauns.
I'm afraid I'm with Stephen Fry on the utility of having swear words in your vocabulary, and have come to the conclusion that you are a smug cunt.
I never said I have a superior sense of humor. Just that I was exposed to good humor so I laugh for something more refined that swear words.
If I were a great humorist I would have a different job which would not involve writing code.
Anyway the Leprechauns were referring to Irish DPC - for obvious reasons, given that context - not the Irish people.
I gave you an upvote as I can see exactly what you are referring to. But then again I KNOW that I am the "outlier" so not really suprised that I empathise with you. Over the years I have met some very petty and childish people in the working world. I freely admit to being a bit of a child trapped inside of an adult myself but there are times I see things that make me think WOW.
"Writing software for me was and is also a show of skills and elegance - not a show of how much childish I could be. But maybe I'm the outlier." - this is EXACTLY the way it should be!!!
I didn't, but what tempted me to downvote most is precisely the "show of skills and elegance" bit. Lord please save us from all code written by people aiming to show off their skills and elegance. Code is not art, code is a blunt tool driven entirely by purpose. Sure, I like pretty code as much as the next person, but at the end of the day, there is only one arbiter of code quality, and that is the customer. And he doesn't - and shouldn't! - care how slick your abstraction layer is.
All code bends to serve requirements, and code that cannot bend - because it's locked in place by excessive constraints, such as demonstrating the author's refined skill - will break, or be broken.
Like a death at a birthday party
You ruin all the fun
Like a sucked and spat out smartie
You're no use to anyone
People mention murder the moment you arrive
I'd consider killing you if I thought you were alive
What kind of creature bore you
Was it some king of bat?
They can't find a good word for you
But I can ...
Twat
John Cooper Clarke
I wholeheartedly agree, LDS. I far prefer my humor to be non-scatological, and work with a team professional enough that I would be deeply shocked to find such language in source code.
There’s nothing wrong with being in the minority, especially in regards to things like not having a pottymouth.
(Anon to avoid long-term flamage full of such language…)
My first jobs were in aerospace in the late '70's. We didn't have code reviews, but once code was stable enough to be be released, the listing had to be published in a paper report that got filed away in documentation control. And each time it was revised and a new release went out. So you had to keep it clean because your name was on it and you didn't know who might glance through it.
I do know that in some of the physics code for the 'special spicy rocks' development - the physicists/programmers used the names of famous Russian theoretical physicists in the code. Then when nobody commented, branched out into using former soviet leaders and heroes of the revolution.
LENIN and STALIN suited the 5 letter name rules of the Fortran system at the time.
From memory (damn, it's been a long time and I don't mind this), the five letter rule refers to the number of letters that are considered significant in a variable name and anything beyond this was ignored.
Therefore STALIN and STALINGRAD and STALIA are all considered to be the same variable. Much fun can be had with such things if someone were evil enough to use words that sounded shorter than they were...
Regarding only n-characters of variable name uniqueness...
I think they fixed that in FORTRAN 77 but in earlier FORTRAN 66 that was probably true for most compilers. 77 added other more structured syntaxes, like if/else and so forth [if i remember correctly]. i haven't worked with FORTRAN since the 90's but even then you had cases of older 66 code being used alongside 77 code simply because earlier machines only had 66 compilers... (and so the original code had been "maintained" for long enough it still had 66 syntax in a lot of places)
[the code in question ran on VAX and HP3000 systems)
I forget if Pascal and early MS C compilers did the same thing, but with more than 5 or 6 characters...
IIRC there was a character limit for (at least one) MS-DOS linker (7 usable chars?), so the compiler could tell the difference between longer names within a compilation unit but more colourful words were spoken when we tried to link each others units into an exe.
> "If we reach here then the ladies bits are pointing skyward"
Not confirming I've ever done this(cough), BUT if I were to put a comment like that in, it would look like this:
"If we reach here then things have gone Tango Uniform"
If the error is particularly bad:
"If we reach here then things are Foxtrot Uniform"
An ex-colleague of mine wrote a small cgi app for a web page. It was just a perl script for an internal website that some users needed. Can't remember for the life of me what it did, but a user came to me one day massively offended and telling me that one of our website was giving him an offensive error message.
I went with him, and luckily the error was still on screen. It just said "Get back, thickyhead". I recognised this as an in joke amongst the team. It was a jokey way of saying you are being stupid.
I spoke to the app's author. He'd put the error in there for his own amusement as joke, along with a load of others, but had missed it when he changed the other errors to errors that were more meaningful, and less likely to cause offence.
I was actually quite sad that he had to change that error as well.
If Brad is still writing code, and now understands logical operations, I bet he's implemented base36 just to give himself some more options and/or a better possible vocabulary..
I run source code through something that checks for swearwords, licence keys etc before it's published...basically if I or a team member have made that mistake before, it's trapped here. The added benefit is that it keeps you up to date with current foul language:-)
Hint: Do not tell the junior team members about Roger's Profanisaurus, unless you like playing sweary whack-a-mole!
This post has been deleted by its author
"I run source code through something that checks for swearwords"
I can assure you that the English language is quite flexible enough to get objectionable phrases past any rules that they choose to implement. That kind of filtering is worse than useless in that it takes time to implement, doesn't work, provides a false sense of security, and opens the company up to lawsuit should an employee accidentally see something that they think was missed by the filters.
Student: "You wont find a single word in my paper that one couldn't say on Radio 4!"
Master: "Yeah, but not in that particular order ..."
A slight aside...
Colleague at a job a long time ago received a mistakenly addressed email from one brother to another, expressing in colourful terms the older brother's dismay at finding out his sibling had come out as gay.
When he replied, to let the sender know the missive hadn't reached its intended recipient, their firm's email filter rejected it due to the level of profanity contained, none of which my colleague had added to...
I have a recollection of a case where was no profanity involved but some expressions not normally used in business conversation.
One of the users of a system had put an annotation on a transaction suggesting that the female representative of another firm they had spoken to had "been on the beer last night" and as a result had "engaged in consensual sexual relations" that had left her "more than normally insensible" that day. Imagine their surprise when they deleted their joke annotation only to find it appeared on the audit trail which was shown with the transaction. For surprise read stress, concern nay even outright panic.
Definitely! That's the 'whack-a-mole' game I was on about:-) Every so often, I find one of the little darlings has tried to be smart and use, for example, 'C0ckwomble'....but they have forgotten that to be old and wise one must first have been young and stupid...meaning I look for things like that. I only check for obvious single word 'nasties', recognising that filtering for everything offensive is impossible. Their latest attempt at obfuscation is to put URL-encoded links to foass.com in the comments:-)
Seen that in action. Anyone with ancient Mac programming experience has written something like
#define appleMenu 1
#define fileMenu 2
#define editMenu 3
And now imagine a tool that drops special characters, digits and line endings and complains about a lot of nudity! (It destroyed some files before we figured out what happened).
> I bet he's implemented base36 just to give himself some more options
Brad sounds like the type of guy who'd implement it in base 69, tee hee.
Either that or base 420 because it's a naughty reference to marijuana that'll never not be the funniest thing ever!!!!!!1111
Well, not at least until you leave college.
Yeah, just take a look at https://thedailywtf.com/ for inspiration.
The appropriate words will pop into your mind. It is just that most never reach the vocal chord system or other's auditory system.
Some very-many years ago, when IBM used to release the source code of their various operating systems on microfiche, a customer hailing from the mid-West of the US (yes, yee-haw...) had complained to "IBM Management" that one comment in a 360-Assembler comms code module read:
"Retry 10000 times, for the hell of it".
The hapless originating IBM programmer was required to change the comment, so that next time round the source code line bore the revised text:
"Retry 10000 times"...
Very minor FYI, but "yee-haw" would be more appropriately associated with the American South. More the central part of the south to southwest. Texas, Oklahoma, Arizona, New Mexico, places that are generally sun-blasted deserts. The US mid-west is mostly farmland, and while you may find farms that have cattle, there's generally enough rain to produce ample grass for grazing that you don't need to herd the cattle long distances.
Be careful what you ask programmers to change
Back when the original PA-Risc systems were get close to release some marketing zeeb complained that the status LEDs inside the 840 read 0000 when the machine was lightly loaded. Not sexy enough, sure said one of the engineers we'll just flip the status bits and leave the load counter as it is.
The comment clearly when several miles over the head of the zeeb but happy he was being listened to the change was agreed.
On the 840 this status panel was hidden away inside the machine.
On the super duper 850 which followed it the status panel was proudly displayed on a thing which looks like a calculator on top of the system where everyone could read
F0FF
I'm rusty, but...
DEFFNfarkFOR f@ck = 1 TO 10
MyWindow.Print STR$(f@ck)+" ";
NEXT
ENDFN
Something like that (with interesting rendering by the site!). Yeah, it looks better in C...
Protip - be sure to add some binary shifting next time. VB5 (and possibly VB6?) didn't have a binary shift operator, leading to some horrid code with divides and multiplies a plenty.
And i'm not the only one ...
There is some sense of relief when trying to debug someone else's code and come across a comment of
// FFS
or code that has been written by team A, then handed over to team B and has comments along the lines of
// who in their right mind thought this was a good idea
#ifdef BURN_IT_WITH_FIRE
[.. lots of code ]
#endif
And I've seen similar comments around my own code, that was coded up ever so clever and making use of arcane template knowledge that meant my code was awesome, extremely succint, nicely formatted and impossible to modify without basically having to rewrite it from scratch
And I've seen similar comments around my own code, that was coded up ever so clever and making use of arcane template knowledge that meant my code was awesome, extremely succint, nicely formatted and impossible to modify without basically having to rewrite it from scratch
You wrote it in Perl?
Best one I saw in our code base was:
#define GO_HOME_WINDOWS_YOU_ARE_DRUNK
in code that was working around quirks of MSVC.
A different part of our code base has a function that cleans up child processes, called grim_squeaker - long ago tribute to PTerry and Death of Rats, from my younger self.
I just cleaned up a piece of code about to go commercial, that childishly I know, featured all kinds of punes (or play on words) around the fact that the description could be abbreviated to R.E.A.P and so had to remove the Non Timetus Messor window title, or the little scythe in the icon ... or ....
In a previous life I was a Foxpro programmer. Ca 2.6. We did a lot of small custom databases and associated data entry screens with reports. We knew our clients well and often managed their micro LANs and computing needs at the time.
Co-owner of the company used to put Easter Eggs in the code that would only appear very briefly when certain users were logged in. For example, in 1 in 100 or so +random offset, error messages would appear very briefly, "You've done it again big nose" and "Well, that was smart you waste of space". Then 2 or three seconds later, the regular error message would appear. No offensive language per se, but enough to make one say, What?
Messages and variability changed with each upgrade too.
A long time ago while at university writing a program in a functional programming language with an interpreter that was slightly less robust then a tissue paper ocean liner I had to insert a comment line with the text (translated) "If this comment line is removed the fing interpreter throws a fit and crashes!"...
In a probably different functional language, you could do comparisons with function pattern matching or a case statement. The pattern matching would only do exact values, so if you wanted to do something as complex as checking whether a number was even, your only choice was case. The problem was that you could only do a case statement in the return from a let statement, which when you wanted to look at the parameter you already had was not required. This led to code like this:
let int WasteMemoryAllocation = 0
in case [your real check]
end
Hey, I had the exact same WTF moment on a multithreaded C compiler for DOS * in the 90s
The compiler would bug out with an error along the lines "you shouldn't see this error message", add back exactly 1 comment line and it would compile fine.
IIRC the compiler was from a one man band company, and yes up to a point did somehow give you multithreading on DOS but eventually enough unexplained crashes occurred that I refactored my code to be single threaded and then all was good.
I worked on a development whose customer was UK MoD. It was embedded code, so was never expected see the light of day. The contract allowed the customer the option of a code review as part of sign off. The MoD QA bloke, let's call him "Mike", was a pain in the arse* and, naturally, insisted on doing the code eview. There were many comments in the code along the lines of "..another error trap for a condition that can only happen in Mike's head...". No four-letter words or direct insults but he was very (and quite rightly, in hindsight) miffed by them and we missed delivery and incurred extra costs because of the work to take the comments out and repeat testing and, of course, code review.
*He also insisted on a formal test to prove that the keyboard worked - every individual key, every allowable key combination plus hours' worth of random multiple key-presses all tested, witnessed and recorded. It took two days, plus the time to write the test procedure and report.
I think that's one of those important life lessons.
So at Uni, we were given the task of writing a traffic light control system in 68K assembly language. Simple enough, light sequence, timers, loop it and call it good.
But then a whole lot more coding so it'd monitor failure conditions, and hopefully not end up with lights controlling a busy crossroad going all green. That bit did have an expletive.
Then more expletives when the lecturer told us we needed Z. I'd have preferred to have >4KB RAM on the dev boards instead. It did teach me the importance of exception handling though.
I once worked with a group of naval architects who had developed some seemingly advanced FORTRAN programs for hull design. They were, however, not programmers and the variables were a combination of women's names and wishful thinking.
The code was supposed to get ported to a new platform, but it never happened: the IT staff couldn't work out what the code was supposed to do and the original authors couldn't understand why the different word lengths on the new machine screwed up all their COMMON blocks and character manipulation.
They stopped building ships soon after.
One of our directors went to South America to demo a system that involved a custom keyboard and driver. A new keyboard driver was installed just before he left for the demo.
One key on the keyboard didn't work for some reason.
That key happened to be for a character that contrived to be used for either the userid or password of every single user set up on the demo system, including all the admins.
Colourful language ensued...
I'll just say, I'm self-taught and my current project at work is refactoring code that was written by somebody with a proper degree. That code is so scary that nobody wants to even think about it (except me, because I'm stoopid and volunteered).
Large sections of code, commented out with no explanation. Chains of three or four functions calling each-other, with names that only differ by one letter (so knowing which one you are actually supposed to call is Russian Roulette). An entire thread just for managing the window size. Completely pointless derived classes (because at some point 2 years ago they thought there MIGHT be two versions that differed in a particular way, which there won't ever be, as evidenced by the fact that one of the derived versions stopped working ages ago due to changes in the base).
When I started my job a year ago, I was worried that my liberal arts background was going to be a problem. I no longer have that fear.
Being self-taught can mean a lot of things - for example, it can mean having learned enough to get the job done, once, messily, or it can mean having the drive and curiosity to learn every minute detail of a thing, alongside proper standards and processes, that your average "trained to degree level" person hasn't bothered with, because they never did a module on it.
As it happens, I'm trained to degree standard in a completely unrelated field to the one in which I work, to the extent that I can tell you how the semiconductor junctions in the processor chips work as well as how to write maintainable and efficient software that runs on them. Some of the best developers I know (all of whom are hot on good coding standards) have degrees in the physical sciences and not in CS. Some of the worst ones I know are also self-taught, so the conclusion isn't whether someone is self-taught or not, it is whether they are any good at teaching themselves.
"Large sections of code, commented out with no explanation. Chains of three or four functions calling each-other, with names that only differ by one letter (so knowing which one you are actually supposed to call is Russian Roulette). An entire thread just for managing the window size. Completely pointless derived classes (because at some point 2 years ago they thought there MIGHT be two versions that differed in a particular way, which there won't ever be, as evidenced by the fact that one of the derived versions stopped working ages ago due to changes in the base)."
Looks like you're into some openssl code review, right ?
Needed to add delays for an undocumented flaw in a chip, and consequently needed to at least document what was going on in the code in comments. I made it a jeremiad starting with a quote from the walrus and the carpenter.
Auditing code can be a tedious task and that section always broke up the day for the auditor such that they insisted it should never change.
During college, a CompSci friend and I were paid on a consulting basis to "take a look" at a malfunctioning program written in an old dialect of BASIC, which meant variable names were limited to two characters at most. This program was ~supposed to~ keep track of appointments in doctors' offices, but its ISAM-like data files were being corrupted, and data were being lost.
We started by printing it out from my friend's IBM PC. We laid out his Citizen dot-matrix printer on his floor, hooked up a fresh box of fan-fold paper, and let 'er rip, thinking we'd read the source as it (slowly) printed.
As we read, my friend began swearing, and I was pounding my fist on his carpeted floor.
To save memory, or to obfuscate the souce, the guy who wrote this horror crammed as many statements on each line as he could. When it was fully printed out, the paper stack was four inches high.
It contained ZERO comments, and the program came with ZERO code-relevant documentation.
The programmer lived somewhere in California, USA, had quit providing bugfixes, and disclaimed any further responsibility for the thing. My friend and I made a pact to give that guy a mild(-ish) beating if we ever encountered him.
> It contained ZERO comments, and the program came with ZERO code-relevant documentation.
While it does contain /some/ comments, there's behemoth chunk of Perl that I've occasionally had to wade through at work. Around 8000 lines and most of the few-and-far-between comments are about as useful as:
"# include_data method
sub include_data ... "
Gosh... thanks for that. And as mentioned, no documentation. Job security, I guess.
Many years ago, when I was a young COBOL programmer, I occasionally had to maintain code written by a guy who had moved on to become an IT journalist - presumably because coding bored him.
His code contained identifiers such as "mekon", "anastasia" and "creosote", while the variable declarations in one program spelled out this timeless message:
the_queen_and_prince_phillip
waved_and_smiled_today
as_hordes_of_unemployed_miners
hurled_pitprops_at_the_royal_yacht
One of my colleagues got so fed up with this that they worked out what "mekon", "anastasia" and "creosote" were actually used for and did a bulk edit to provide more helpful names.
In the same establishment, we maintained a transaction processing system, where each transaction had a 4-character identifier.
The powers-that-be were disappointed (shall we say?) when the logs were examined, to see what the operators tended to enter into this field when they were bored. A colleague was tasked with writing a routine to check the id for rude words and display a "wash your mouth out with soap" message when they occurred, butI don't think that in the end we ever actually implemented it - he was looking forward to compiling the list, though.
Fortunately, modern IDEs have refactoring tools built in, so you can right-click-rename troublesome variables without having to manually go through the entire codebase and find all the references.
Unfortunately, a good deal of our code-base is not written in a language that has a modern IDE.
C'est la vie, n'est-ce-pas?
I just used to occasionally put in a comment along the lines of
# You need 5 beers to understand this code
More often than not, it was copious comments about what the hell I was thinking when I wrote a particular piece of code. Very useful when you find out at 23:30 on New Year's Eve that someone changed an API and never bothered to tell anyone, let alone update any engineering specs (which I had to use originally to write the code). Did I swear a bit in my comments around my impromptu update? Of course, but as I was the only one who knew how to maintain the code and there was no-one else around to review, let alone understand it....
I often leave comments along those lines in my code as well, usually when I was doing something stupid because the right thing meant a rewrite. For example, "I don't know who originally wrote this crap, but the newest pile is mine. {explain why}"
In pre-covid days, I would often discover that someone was making an update when they started laughing.
... when I was working as an intern refactoring some old code and found out someone was using some verses from Deutschland über alles to test UTF-8 encoding.
I thought it wasn't explicit enough so I took the time to find and replace the string with some verses (I believe) from the north korean anthem. I commited the changes and patted myself for being a sneaky edgelord.
I was disabused of that notion when my team leader called me the next morning to personally explain how git blame worked
The software I work on every day still has a very old CrapCredit credit check function from before I started there over 16 years ago, so when attempting to place an order it will be rejected if CrapCredit() = true.
A few other examples of inappropriate naming in the codebase have been cleaned up over the years, but CrapCredit() still endures.
I employed a team that were about 50% UK citizens with the rest from all over the globe, (but currently resident in the UK). I am talking last century here, so a very uncommon team for a provincial town.
Meetings were often "fruity" as people struggled to express themselves adequately.
However, Max, a Ukranian who had been a conscript officer in the Russian Army (based on his ability to read and write), took the biscuit when Mr. Chen started. Unbeknownst to the rest of us, Max had given Mr. Chen a copy of Roger Mellies Profanisaurus to expand his vocabulary over the weekend.
Thereafter, Mr. Chen greeted everyone (both sexes) with the phrase "you dirty git" and the insults he threw into general conversation were quite legendary.
He went on to be quite successful, despite his language and the fact that European attempts to say his given name resulted in something very rude in Chinese, which always made him red with rage.
Not in code - and I am self taught in V Basic but had already cut my teeth in other languages beforehand. My boss needed something putting together and gave me the spec, told me to use Visual Basic to do it. Spent a day or so trying stuff out, wrote the code, fully documented it and everyone was happy. No swears or dodgy comments.
In graphics, however... Our publisher wanted us to write a game based on the fun fair thing called Kentucky Derby, where you throw a ball up a table to make a model horse run along a track. We thought it was a crap idea but he insisted, so we did it, and, within the limits of the actual gameplay, made a decent job. The throwing hand, though, I made it look like it was moving in a manner more reminiscent of a (ahem) Hand Shandy, which was picked up on in the reviews, and rightly so. It was our not so subtle way of commenting on the game concept.
AFAIK, you can still find the game in various 8 bit archives. It was released for the Speccy, C64 and Amstrad 8 bits. The game's called Kentucky Racing.
....he was working on his own, writing an enterprise-level application for his employer. I was drafted in to review Brad's project, since the local management were interested in getting an independent view of the project (since around $200K had already gone, with no end in sight).
Well......Brad was interesting to talk to:
(1) No visible project plan
(2) Not even rudimentary requirements
(3) Not even a rudimentary test plan
(4) A CV that said he'd never done anything remotely like this before....
(5) ...and a pretty robust attitude to simple questions (you know....Who do think you are?)
Sometimes you wonder what managers actually do!! It took them $200K down the drain before they started to wonder!! As for Brad.....who knows!
Ah, the days of putting humorous things into code... back in the day when I found myself running databases on Netware (don't ask, I still have nervous twitches) we occasionally saw the OS fall over reporting a "richard kiel memorial abend".
https://eeggs.com/items/28509.html
We reported it, and Netware fixed it.
The abend still happened, but it produced a more straitlaced error message :)
I wasn't aware there was another way to learn VB in the mid-90's other than plowing through the two manuals that MS shipped with the disks, and maybe get a couple of VB books from the local bookstore. But then, I was in CompSci, and I recall the CompSci profs deriding it greatly. Maybe the InfoSys profs in the Business School taught classes in it. VB wasn't great, but it was a way to keep the kids fed and in clean diapers.
Most of my swearing was in comments, and 90% of the time consisted of the phrase "...fucking Microsoft..."
"The primary purpose of the DATA statement is to give names to constants; instead of referring to pi as 3.141592653589793 at every appearance, the variable PI can be given that value with a DATA statement and used instead of the longer form of the constant. This also simplifies modifying the program, should the value of pi change." -- FORTRAN manual for Xerox Computers.
> should the value of pi change
We were always told that the most accurate value of Pi you could use was "4.0*atan(1.0)" (yeah, FORTRAN). Then I started working on GPS applications in the 80s and the official ICDs mandated a very particular value of Pi that had to be used when dealing with GPS positioning. So, while it didn't necessarily change, a specific value might be mandated. (Though not as ham-handedly as the Indiana legislature tried one time.)
I once ended up testing out of a class because we had an assignment. I forget what the assignment was, but I had a switch/case statement, and being a proper little coder, I had an "else" catch-all at the end which would error out saying something like, "I don't know what the fuck happened" because that condition should never be possible to meet. Professor gave me a zero on the assignment just because I used the word "fuck" and I went over their head to the dept. chair to arrange to test out of the class after that. There was also the fact that the professor would spend like half of any given lecture period talking about his time in the military, then the class was expected to just figure out how to complete assignments on their own time, and I didn't really feel like paying some obscene sum of money to listen to this guy reminisce.
I'm fairly confident that I would have gotten a 0 if I had included unnecessary obscenities in pretty much anything I ever submitted to a class. I'm thinking through all of my profs. I think their reactions would have ranged from " low-grade and a stern note in the edit" to "don't come back to my class".
Not trying to claim I'm the hero of the story. Don't remember why I did that now, just that it seemed like a good idea at the time. Still, it did anger me enough to test out of the class and I could then put that time to better use. Also meant I didn't have to go into the CS building anymore. The smell of BO was like a solid fug in that building that would smack you in the face the moment you walked in and took your first breath, constantly being recirculated by the cooling fans on all the computer systems.
Still, when the Microsoft source code leaked some years back, the whole argument that this sort of thing would get you fired in a professional setting kind of went out the window. As long as it wasn't in a customer-facing error prompt or something, no one would really care.
Had a tutor in Swindon, nicknamed after a certain reactor went into meltdown in the 80's, who loved any excuse to get into his favorite subject of Partial Address Decoding.
We had him for about 90 mins in a Motorola 68000 environment, programming with a hex keyboard & little in the way of guidance as to what we were supposed to be doing.
Then we had him for the whole Wednesday afternoon (Always chucking it down outside), trying to stay awake, many of us failed at that & then someone would trigger him.......
Icon - Because the afternoon was going to be a write-off anyway!
... in a company involved with engineering and drafting, it was common to find little Easter eggs in the drawings. One instance did go over the top though. When drawing very long objects, it is common practice to 'break' the object in some featureless region and to indicate the break with a squiggly line at both ends of the discontinuity. One drawing of a wing spar was found to have a couple of unusual break symbols that, when the drawing was folded to bring the symbols together (similar to the back page of a Mad Magazine), it resulted in an outline of a rather comely wench.
Due to the lack of humor in management (and the risk of a possible harassment suit), the drawing was re-worked and re-released.
Now it's quite difficult not to visualise that.
I suppose that most of the James Bond films titles, "Tales of the Unexpected" titles, and some "The Two Ronnies" episodes, possibly the one where Ronnie Barker is got up as eccentric television astronomer Patrick Moore for instance, prepared me to do so.
On one memorably miserable project in the last century (single-handedly creating software support for a portable instrument; the full requirements list was: "We want it to talk to the flowmeter", and you can imagine how fast it went down hill from there), the Sales folks routinely gave out internal-use-only alpha test copies of the software to customers, in violation of explicit instructions to the contrary. Salesmen were always trying to steal a march on the others by showing off the newest (buggiest!) features.
Until I added a profanity-laden startup splash screen stating that this test version was for <expletive> internal use only and NOT for <expletive> distribution to customers.
And waited (not long) for the complaints to roll in from Sales. Which were then countered by a reminder that, as they had been repeatedly warned, they weren't supposed to be releasing alphaware to customers.
swear in the comments, or stick in things like "here be dragons" as a label for some calculation to map flat tool paths to rounds bits.
A couple of previous programmers generally used swear words as lables and program names... along with opinions of the manglement/customers in the comments
Thank gawd we keep all code internal only
<<gibbers slightly at that suggestion by the deputy mangler about giving away source code to a sub contractor ....
"A couple of previous programmers generally used swear words as lables and program names... along with opinions of the manglement/customers in the comments"
Some years back, the suggestion was mooted that customers should have read-only access to their call-outs in our service and maintenance database. It was pointed out that those who came up with the idea should have a read through some of the fault resolutions entered by field engineers. IIRC, the eventual decision was that the time to sanitise the engineers comments would cost more than the projected customer benefits might be.
Mostly self taught here (one quarter of Fortran in the 70's). Much later in life I entered a self-taught phase.
I am a little surprised nobody else had a story like mine, though, self-taught or not.
I still recall being righteously incensed the first time the language I was using (can't recall which) complained that I had named a routine with a reserved word. I believed I had found the perfect descriptive name - it really shouldn't have offended me so much that I was right, just not first. It did turn out that what my routine did was not closely related to what the reserved word referenced. So no, I wasn't reinventing a wheel here.
The >second< time it happened in the same session I went to a place that I strongly suspect Brad reached and basically said, "OK, I bet THIS &*#^ word ain't reserved anywhere." But I wasn't able to hold on to the mood long enough to move all my names to the dark side. Although Brad's example doesn't make for a good role model, his dedication is impressive.
I still recall being righteously incensed the first time the language I was using (can't recall which) complained that I had named a routine with a reserved word. I believed I had found the perfect descriptive name - it really shouldn't have offended me so much that I was right, just not first.
I've tripped on something similar in GCC several years ago, only in this case it was a poorly thought out extension that would conflict with a function called "index". Not a reserved word in C but that version of GCC didn't like it in default trim.
I believe it's been fixed now but that kind of stunt instantly causes you to lose faith in a tool. If some numbskull with an ego thinks he can "improve" things by deliberately causing valid code to fail what else is lurking in there?
This is in our current code, and frankly I'm quite pleased with it.
Our equipment uses plain-text commands to tell it to move things around and store settings. We needed to be able to erase settings as well though. At the time we had no protection against customers seeing our internal-use-only commands, and we weren't sure that production wouldn't do something silly either.
The erase command is therefore called "stage.calibration.full-erase-of-entire-eeprom-with-no-undo-be-very-sure-before-doing-this".
Our kit has been in production for 9 years now, and so far no-one has unintentionally erased settings. I'd say that's a win.
Back in the 80s, VMS had an optional security feature that could prevent users from choosing their own passwords, instead forcing them to choose one from a list of 5 random "generated" passwords. Of course, there was always the possibility the OS could generate a password with a naughty word in it, so there was allegedly a list of words which could not be used.
Source code was on microfiche in those days, so sadly I never was able to add to my vocabulary by finding the de-facto list of forbidden words!
Perhaps those who are more easily offended could use Scunthorpe Sans font in their IDE?
Many decades ago, I wrote a very rude warning in the comments surrounding some Informix 4gl that I had to work around to get a display/keyboard input to work despite their really crappy character management engine.
Some years later, a team member working for my BH came across the code as their company had taken over my old mob.
As I always sign off and date comments it was... embarrassing.
Might this have involved some consultancy that decided it was a really good idea to create a lot of macros that expanded to provide ring menu text? And use them copiously? The macros that then clashed with built-ins in a later version of 4GL? I remember a long Sunday evening after an update with three of us going through a large suite to get it in working condition for the next day. Once we'd worked out what the mysterious problem was. At least there was no swearing in the non-existent comments.
We had a programmer that who hopefully is still no longer a programmer.
The variable names he used made derogatory comments about the customer.
Comments in the code also made even more derogatory statements.
It was before the days of being able to stop check-ins until they had been approved.
I ended up having to review every single line of code and every document before we delivered the system to the customer.
TBH this is the only time in 35years that I've had to deal with something like this.
Major mistakes:
1. using VB as a production ready language
2. using Access for anything (remember the old 65k records then fall over issue?)
This reminds me of VB code that had >5000 lines (this is one function) and > 40 paramaters because the object that containerised them only existed in the local namespace, then putting them all into the object, then using them all in another function call because it was external.
When I was a new developer, I used to leave rather rude excecutives in the git messages whenever I would get frustrated. I never considered that years later people might dig back into that history! It was pretty embarrassing because the recently new manager at the time didn’t like me, and was always bringing me up on it. Fortunately I quit not too longer after, but it makes me feel warm and fuzzy to know that my sweary messages have been immortalized.
I've spend my whole life as an Engineer working with American & British engineers so my spelling tends to reflect who I think is the bigger audience, which is often Americans. Thing is I find myself using American spelling more and more, especially spelling that does away with a single letter. It's more efficient after all.
I've not started calling a boot, a trunk though, at least not yet. A boot has one less letter than trunk so all you Americans out there should start calling your cars trunk, a boot for the sake of efficiency.
I'm not sure about calling a British car's front a Bonnet though, hood is better. So from now on its hood and boot. OK.
I never swear in code, but would still laugh at the odd word, but as I've got older I swear like a trooper in real life especially in our currently dis-functional world.
Can't get a GP appointment for love nor money, yep **** that, lazy *******.
Can't get a walk-in x-ray at the local hospital without making a appointment and waiting another two weeks. Holy ****. You know in the old days you could just walk in and get these tests same day ! Useless ****** NHS.
And people put up with this ****. It doesn't need to be like this.
Maybe it all went wrong with the smart phone. Too many hours wasted on forums/Facebook/YouTube rather than getting on with your job.
******* Smartphones.
Or maybe it all went wrong when the NHS rolled out PCs. You won't believe how inefficient a PC can make you in the admin department. What's the solution? **** knows.
I used to work with a guy like Brad. Don't get me wrong, I don't particularly care about swears in comments etc. I tend to prefer snark and sarcasm myself. But our version of Brad just swore for everything. Every variable and function name a profanity, and not particularly inventive ones either (especially when it got to f@[#1, f@[#2 etc). Like Brad, it just got in the way of every other developer who worked on the project who now had no idea what his code did. He even authored it with made up names.
As a newbie encountering his code for the first time, I turned to my mentor and indicated the name in the code. Who then turned and shouted the name across the room, and everyone turned to look at Brad, who was now turning bright red and trying to be as small as possible.
He didn't stop doing it though.
I used to do student tech support, so I've seen a *lot* of buggy source code.
One website springs to mind.
The students had been given a small project Basically, they needed to create a small webstore that offered the ability to save the user details (including any trolleys) into an account.
One user reported that his site wasn't allowing any logins.
I expected this to be an easy fix, as the other students doing the course had simple problems. In theory, his problem was simple. Unfortunately, it was complicated by the fact that he'd given the variables he was using reference codes (A1, A2, B1, B2 etc) with no apparent reference anywhere regarding what each variable was supposed to be storing. Not only that, but he had 52 of them.
I think what had happened was he'd plagerised different bits of the code from different places, and they each had their own variables.
Unfortunately, despite being a good coder myself, I really couldn't find my way through his source code, and as such, couldn't fix his problem.
I had to advise him to talk to his lecturer. Bearing in mind nearly all his code was plagerised, I suspect he didn't.