Keith received a ticket regarding a very large, very important, and very complex application, written in Perl. Keith’s first step was to scan the file for variables, so he could get a better sense of things he should look out for.

He found this:

 $blank1 = " ";
 $blank2 = "  ";
 $blank3 = "   ";
 $blank4 = "    ";
 $blank5 = "     ";
 $blank6 = "      ";
 $blank7 = "       ";
 $blank8 = "        ";
 $blank9 = "         ";
 $blank10 = "          ";

Confused, Keith tracked down the developer responsible and asked why it was there.

“Sometimes I needed to check how many spaces were in a given string,” the programmer explained.

“What if you needed to check for something with 11 spaces in it?” Keith meant the question as a joke.

“Oh, then I just concatenate $blank1 and $blank10 together. It’s very extensible !”

[Advertisement] BuildMaster allows you to create a self-service release management platform that allows different teams to manage their applications. Explore how!