Truthful Strings

2010-09-08

Like virtually all modern languages, C# has a built-in Boolean data type. This means that the only values eligible for variables of that data type are true and false, and unfortunately not FILE_NOT_FOUND. In addition, all data types in C# have a ToString() method, which does just that; for Booleans, it returns the appropriate of the two constants System.Boolean.TrueString or System.Boolean.FalseString.

So given that (which, you probably already knew anyway), how would you convert a Boolean to its string representation? If, like Malcolm colleague, you answered the following, give yourself a point!

Insurance is a complicated industry at the best of times. At one firm, it was made more complex by the Policy Entry system. A Third Party Administrator(TPA) negotiated a policy with a client, then documented the changes in a rather hefty spreadsheet. The TPA would then call the data entry clerk at Bells-Torgo Insurance and verbally relate the contents of the spreadsheet.

Corey did the rational thing and suggested, "Hey, maybe we can automate this!" It was a straightforward operation, with a clear and well understood mapping between the TPA's sheet and the Policy database. Corey wrote up a design document, which included a diagram to sum the entire thing up in a way a manager could understand.

CAPTCHA'd

2010-09-03

What's that, you say? We should have an entire Error'd dedicated to CAPTCHA images? Sure, why not!


Alex van Herwijnen spotted this interesting problem presented...

The Best (from Chris)
A while back, I helped interview for a programmer position on the web team. After talking to a number of candidates, we finally settled on an older gentlemen, probably in his late 50s. It wasn't an easy decision. Not only were his salary requirements above what we planned to pay, he had a few personality quirks. For example, a large part of his interview entailed him describing how he was a master composer of music, and had published songs in nearly every genre, including country, rap, pop, etc. But no matter, his experience and technical skills were top-notch.

After making an offer that met his salary requirements, the candidate made a counter offer: fifteen-thousand dollars more annually plus a signing bonus. Unfortunately, our budget couldn't accommodate that, and we declined. Negotiations after that failed, so we formally rescinded the offer for employment so we could talk to more candidates.

"I was recently assigned to work on a team that maintains a fairly large product," writes Aaron, "at first, I was a bit overwhelmed by the complexity of the architecture. There were countless layers of abstraction, thousands and thousands of classes, and design patterns galore. Since it was such a large project – and my first large project – I figured that the architectural complexity was simply par for the course."

“Then I started looking at the code a little more closely. If I had two words to describe it, they’d be ‘unnecessary complexity.’ And if I had one snippet to describe it, it would be this.”

Fast Fix

2010-08-31

"Do you think it's wise to have consultants running our IT department?" Holger asked. It was an honest question, worded as diplomatically as possible. Holger's company had more consultants on hand than actual IT staff.

"Holger, these folks are experts," his manager replied. "It isn't cost effective to hire-on this level of expertise full time. We may pay a little more up front, but when we don't need the consultants anymore, we can hand it off to our internal people."

Command 696

2010-08-30

Think of all those old applications you’ve had to maintain. You know the type: the ones written by long-forgotten developers in long-lost languages. The ones that, after spending days searching for that one line of code that needs to be changed, you frustratingly decree “this f%*#@ thing needs to be rewritten.” And, naturally, the ones that never are, nor never will be rewritten.

Call it luck or persistence, but after dozens and dozens of maintenance requests over the years, Israel Brewster finally was given the opportunity to rewrite an application. From scratch. And the right way, this time. No shoddy VB6 front-end; no horribly-designed SQL Server 2000 (only) database; and certainly no Microsoft Access-based administration tool.

Kristján writes, "I agree. No, wait..."

Stoned!

2010-08-26

When Greg was shopping for jobs at his college’s career fair, there was a whole lot of business as usual.

The larger banks were on-hand looking to swoon the upcoming Financial grads. Several representatives from a few big name manufacturing corporations were there to interview the Chemistry majors and a few IT firms were on the lookout for the soon-to-be CS grads, like Greg, to add to their ranks. However, amid the ocean of pamphlets and  suits there was one aerospace corporation with one particular position that caught Greg’s attention. The position that he applied and was ultimately hired for could be summed up in one sentence:

"While digging through some inherited code," writes Joe "M2tM" Smith, "I encountered a conditional masquerading as a loop."

"Thankfully, the fellow responsible is 'no longer with us', and I suppose this type of code stands as silent testament to why. This interesting loop is only created so the break keyword can be used as an elaborate GOTO."

View Article Archives >>