14 October 2015

Do recruiters still need to ask for resume / CV printouts?

In a digitized world, it is quite a paradox that companies still require interviewees to bring a printout of their resume or interview invite email.


If the phrase"save trees" makes you roll your eyes, then please feel free to stop reading. The rest of this blog post requires a more creative and inventive mind to interpret it.


Why in the world would you require printouts?

Assume a company conducting just 100 interviews every three months.
  • That's 100 * 3 sheets of paper on average * 4 quarters a year = 1200 pages.
  • For 3000 companies in a city, that's = 1200 * 3000 = 3.6 million pages a year!!! With that much of paper, you can make 293.49 copies of the Indian Constitution. The bulkiest constitution in the world! As for cost, that'd be 7.2 million Indian Rupees.
  • And oh...in terms of trees, that's 432 of them.
  • On top of that, you also want candidates to carry a printout of the interview call email?
  • Some companies even expect candidates to carry and submit photocopies of their marks card and resume even if they have not yet been selected by the interviewer (when you ask a candidate to submit exactly the same details a million times, it's a sign that your recruitment process is messed up. Ever heard of referential integrity?).
  • Then there's the entering of candidate details on a bunch of paper forms!


Seriously, HR departments...haven't a single one of you considered moving into the digital age?



What can be done:
  • Let interviewers use their work laptops to view documents
  • Specifically ask the candidate not to bring a printout of anything
  • Candidates can email their resume and scanned copies of other documents.
  • They can bring a copy of the interview call email on their smartphone (a copy of this email is usually asked for by the security guard).
  • If candidates are expected to fill in their details in a form (do you even need a form? Why not fill in details after being selected?), allow them to do it via an online form (perhaps even a day before the interview). You could even create a user friendly form that could be used on a smartphone. Create forms that  can be shared with the candidate on the smartphone via bluetooth (if the candidate does not have connectivity to the internet).
  • If the candidate wishes to share any additional documents, it could be done either via Google drive, bluetooth or via a pen-drive or rewritable CD/DVD. Make sure you use the pen drive on either a Linux or Mac OS, to avoid those annoying Windows viruses.

Yes, I know you might be a company which has very strict security and device policies. Do understand that these policies and security are meant to prevent sensitive company information from leaking out; not for preventing candidate information from coming into the company.

A creative/inventive mind will always find a way to create facilities and spaces where interviews can still be conducted with a minimal use of paper.
Once you've become digital, shout it out! Let the world know that your department is awesome! Spread the news. It really is time to get out of the feudal age.

No more printouts!!!

If you want to hear the magic word before going digital, here's me saying "Pleeeeeeease!!!".


07 October 2015

Automation: Script to set up tabs for you in a single terminal and run commands in them

I noticed many colleagues loved opening up multiple tabs in a single bash terminal, setting title names for every tab and running commands in them. They performed this ritual manually every single day.

The first thought that went through my mind was "Hey, why don't we automate the process?". I suggested it to them, but I guess they preferred doing it the old way. So when I had some free time, I did a bit of finding out and created this shell script:


#!/bin/bash 
#The ampersand in the end of this file makes sure that the gnome-terminal command is run as a background process. 

echo "Setting up environment"; 

gnome-terminal 
--tab-with-profile=Default --title=TAB1 -e "bash -c \"trap 'bash' 2; clear; ls; exec bash\"" 
--tab-with-profile=Default --title=ANOTHERTAB -e "bash -c \"trap 'bash' 2; clear; ls; pwd; exec bash\"" \
&



Place this code in an empty file named sim.sh and use the command 
chmod +x sim.sh 
to make it an executable file and then run it with
./sim.sh

and viola! You have a terminal with multiple tabs! Just replace the "clear;ls" and "clear;ls;pwd" with any other commands of your choice.

The syntax for adding more tabs is:

--tab-with-profile=Default --title=<THE TITLE YOU WANT TO GIVE THE TAB> -e "bash -c \"trap 'bash' 2; <THE BASH COMMANDS YOU WANT TO EXECUTE> ;exec bash\"" \ 



One more thing to do

Having the script is not enough. You'll notice that when you finish running any commands on the terminal, the tab title/name you set, would have gotten reset.
To circumvent this problem, do this:

Go to the Edit menu of the terminal. In Profiles select Default. For the option of When terminal commands set their own titles, select Keep initial title

That's it! Don't stop at this. Keep finding ways to automate tasks and save time!

20 September 2015

How to solve Git merge conflicts using kdiff?

KDiff's windows (or any other three way merge tool's windows) aren't quite so intuitive, so here's some help.

Let's say you've worked on the master branch



and somebody else worked on a "tryingOutSomething" branch





...and you decide to merge that person's changes into your code.



But Git complains that there are merge conflicts!
Turns out the other person was working on the same file you were working on, and also on the same lines.

GitExtensions refers you to KDiff3 to solve the merge conflicts. Select the option to start merging and you see a screen with four sections.

Click image to view larger

The sections from right to left are:

  • Section C: The code of the branch you are going to merge into your branch.
  • Section B: The code of your current branch.
  • Section A: The code that is in the commit which is a common ancestor of B and C. Don't bother about section A. You'd hardly ever use it.
  • Bottom section: It's what your code will look like once you've done the merges and save the file.

You can manually make changes or copy code and paste it into the bottom section like this:

The "m" I've circled in green, is KDiff's indication that it is a line of code that's not from section A, B or C. It's a line that you manually modified.

Or, note that the extreme left of the bottom section is segregated into areas where there are merge conflicts and it shows letters A, B, C or m. Any letters that are present before you started merging (indicated in the image below by the red arrows pointing leftward), are merges that happened automatically. If that's not what you wanted to merge, click on the letter in the bottom-left section and select A, B or C in the toolbar on top (indicated in the below image by the red arrow pointing upward).



You can even edit the automatically merged conflicts and choose A, B or C or edit it manually.


That's it. Now just save and exit, and Git will allow you to commit.



Solution to another issue:

You'll see a residual file of the merge, which has a ".orig" extension. Don't commit it. Just delete it.
In case your merging went wrong and Git says "You have not concluded your merge (MERGE_HEAD exists)", then just go into the hidden ".git" folder and delete the files named:
MERGE_HEAD, MERGE_MODE and MERGE_MSG.
After deleting those files, you'll be able to do the merging again. Do it carefully this time and save and exit.

All the best! :-)

17 September 2015

Aha!

Today is a little turning point for the LOL pages. They are now "Aha's!!!". Laughing Out Loud is not really what happens when one reads the little jokes I put up here. Aha describes the emotion better. Here we go...


Festival Sale
Share with this link




Continued in the next Aha!.
 
 

12 September 2015

It's just about using the Hungarian variable naming convention appropriately


"...and when bmeJames oBond pulled the ftrigger, the sivillian jumped in the mwater."

This is what programmers are put through when reading or writing code in companies where somebody, some-day, misunderstood what the Hungarian notation was actually meant for and created a company policy of naming variables as such.

  • bBusy : boolean
  • chInitial : char
  • cApples : count of items
  • dwLightYears : double word
  • fBusy : float (or flag)

Apps Hungarian is the original Hungarian. Not Systems Hungarian. If your programmers are annoyed with this notation, they are not wrong. See what the creator of C++ and the creator of Linux have to say about Hungarian:

Bjarne Stroustrup:
No I don't recommend 'Hungarian'. I regard 'Hungarian' (embedding an abbreviated version of a type in a variable name) as a technique that can be useful in untyped languages, but is completely unsuitable for a language that supports generic programming and object-oriented programming — both of which emphasize selection of operations based on the type and arguments (known to the language or to the run-time support). In this case, 'building the type of an object into names' simply complicates and minimizes abstraction.
Linus Torvalds:
Encoding the type of a function into the name (so-called Hungarian notation) is brain damaged—the compiler knows the types anyway and can check those, and it only confuses the programmer.


How it all began

It started when Microsoft's chief architect, Dr.Charles Simonyi started it and it came to be known as "Hungarian" because it made variable names look as if they're non-English and also because Dr.Charles is originally from Hungary.
While Microsoft has a respectful article about him, praising how the introduction of the notation helped programmers write better code faster, the adulation could also just be the result of the influence of a powerful person. Given that in the days of the DOS operating system compilers weren't as programmer-friendly, and not being very careful with datatypes could lead to costly bugs when thousands of lines of code were involved, the Hungarian notation could have really helped programmers of that time.


My take on it: The Rudder Notation enhancement

Today's IDE's just need you to hover over a variable to view its type. But inspite of modern IDE's there are people who still find Hungarian useful. It can be useful when maintaining languages which use dynamic typing (JavaScript, for example).

Moreover, although there are various reasons for not using Hungarian, I just need one reason: Readability. We read left to right. Even in the days of DOS OS'es, variables would have been far more readable if the Hungarian notation were used as such:


variableName_typeInformation


Keep the type information away from the variable name with a distinct underscore and keep it on the right side of the camel-case variable. Of course, now that it looks exactly like English, you won't be able to call it the Hungarian notation anymore.

I named it the "Rudder notation" because the type information projects out of the name, pretty much like the rudder of a boat or plane, while also performing the function of guiding the developer or code-reviewer.


Are the variables more readable now?
  • busy_b : boolean
  • initial_ch : char
  • apples_c : count of items
  • lightYears_dw : double word
  • busy_f : float (or flag)

Some people want to use Hungarian because they may some-day take printouts of their code. Really? Then you're very likely doing something very wrong somewhere. Others have written long posts on Hungarian; but really...

...what you need to do, is identify which variables could mistakenly introduce bugs in your code, and apply the Rudder notation to them. This identification is very much dependent on what kind of application you are building, and not on the language or the datatype.

Forming a policy for your programmers to follow by doing a monkey-see-monkey-do of somebody else's Hungarian policy would not just be unwise, it would create a culture where team leads force ideas onto the team without understanding the idea, and cause disgruntlement within teams who don't see the point or value that the policy adds to their work. Instead, educate them to recognize potential problem areas and create a culture where they share this info with each other. Creates a better sense of ownership.


-----------------------------------------------------------------------------------------


Update: Apparently I'm not the first person to suggest the underscore for Hungarian (but I'm the one who christened it the "Rudder notation"). c2.com pointed me to 'experts' who have already encouraged it: http://www.intentsoft.com/hungarian_notat/

22 August 2015

Empathy is not just human, it is the basis for collaboration and survival

A friend pointed me to a post on Empathy and the Global Corporation. A long well written intriguing post that addressed the growing concern about the "rank and yank" system that apparently works well at Amazon, but hasn't really caught on at other companies (and thus hurt their profitability) because human beings work better when empathised with rather than being treated like robots. Which brings any CEO to the logical conclusion that they actually could replace their employees with robots which would help them save costs and beat the competition, thereby gaining a more loyal customer-base. A customer base (read "you and me") who are equally un-empathetic about others; and wanting the best products and service at the lowest cost.
So in the blame-game, the blame shifts from the cruel CEO's to us.

I've interviewed with Amazon, and although I did see some signs of the uncaring nature, I also did see efficiency and caring. I believe that in every random sample of a human population, you will always find the nurturing as well as the selfishness. It's how the human psyche is built.

But I don't see a decrease in empathy around the world. In fact, empathy is increasing exponentially. There were times in the past where people would direct visually impaired people to walk into a ditch. Times when people would laugh uncontrollably at a mentally challenged person muttering gibberish. Times when people would knock off a person's crutches just to see them struggle to get up again. Times when women were denied basic rights. Times when people would laugh at what they thought was a backward culture.
I see less of that happening now. With better information, education and communication across people and cultures, empathy and understanding has grown manifold. That's why as mentioned in greatbong's article, the HR person asks their superiors “What kind of company do we want to be?”.

A similar line of thought was mentioned to me by my colleague. His teacher said that technology has ruined the world. I disagreed. I asked him: "If technology remained primitive and humans just kept multiplying, then wouldn't forests keep getting destroyed? Won't the water and air continue getting polluted? As humans take over the world, won't they eventually reach a compromise with each other but continue destroying the world?".

The real problem at hand is not technology or profitability.
The problem is population.
Two generations ago, the world was still an ok place to live in. And that was the time that people thought it was ok to have 4 children per family. Before that, people were ok with having 8 or even 14 children per family!!! All those mouths to feed and all those living bodies required the resources of the world.  A problem, one would say was addressed by technology and profitability: Creating more space for humans, packing more animals into smaller areas in farms, building transport systems and factories for mass production and delivery, injecting and spraying veggies and fruits with chemicals.
There were the needs of the population, and they had to be met. When the government can ban cloning and monitor a host of destructive attitudes and technology, then why didn't the government prevent pollution? Why didn't the government make laws that could have saved us all this trouble?

----- digression -----
 
Did you know that in 1996, General Motors created a beautiful, fast electric car that ran for 90 miles on a single charge? They gave it a trial run with 300 Californians and then took back all the cars and crushed them.

 
See the video on youtube, where even Tom Hanks expresses how much he loved the car. Some people say it was because there was too much money remaining to be made from selling oil. General Motors says it's because they felt people wouldn't buy a car that expensive. I believe there's also the element of a lot of people losing their jobs because electric cars need neither fuel nor maintenance. It doesn't even have an engine. Just batteries. Countries with high unemployment, also see a rise in crime and riots. Something you'd have faced while playing Caesar-3 :-)

----- end of digression -----

 If the needs of the population aren't met, bigger, unsolvable problems will crop up, leading to a more violent, selfish world. Technology and efficiency can help address these problems. Governments only ban technologies that can cause gross problems, so less-noticeable destructive technologies manage to continue surviving.

Although people fear robots may take our jobs one day and AI would be so dominant that they could take over human civilization, I don't think that's going to happen. Humans are too smart for that.
What we will do instead, is find ways to embed technology into us. We will strengthen our bodies with metal. Add processing power and information access to our brains. Perhaps even entirely replace our bodies with a synthetic material that has our consciousness. Imagine a world where you would never feel hungry. A world where you never fall sick. A world where you could replace a damaged part of your body. Where you could use technology and efficiency to travel to other planets or even create a self-sustaining home in the void of space. Don't discourage efficiency or data or smartness. It helps us take better decisions. And in reality, it helps build more empathy. For as long as we choose to be human, that is.

But even with such a high level of efficiency, would we still give up what it means to be human? It's a question that cannot be answered by a brain that still requires to bond with others or cares for others. But even a machine would eventually figure out "division of labour". The whole reason why a bond exists between anything that is conscious.
History has been witness to the Hemlock Society. An organization that neither accepted the authority of the State nor the authority of Religion. It collapsed. Without the bonding and caring for others, not even an intelligent machine would survive.

For as long as a consciousness wishes to survive, "Empathy" will exist and flourish. Destructive, selfish behaviours will exist in the universe. But that's not an indication of a lack of nurturing and care. For every yin there is a yang.

StackOverflow's 10million+ questions and they are giving away free T-shirts!!! Wait....what???

Stackoverflow recently changed its homepage to say "Stackoverflooooooow". Going a bit deeper revealed they were celebrating the fact that StackOverflow crossed 10 million questions! (I had the impression it'd have crossed 10million a long time ago. Anyway...)


I love StackOverflow and its sister sites. Although I've been active on other forums and the communities are very friendly and helpful, StackOverflow's primary advantage is that it has a LOT of people online and there's a very wide variety of technological help available.
51million users active online per second, is what they claim.
You get detailed, well-researched answers in a voted format with a clean, minimalist interface that not many other forums offer.
StackOverflow also participates in the real world with conferences modeled after Byte magazine which had a diverse range of topics on programming. 


Gamification

Did you know that StackOverflow was designed with the Gamification concept of online reputation scores and medals? During winter, you can even win hats. They don't really translate into anything, but people want it. And they want it badly!
If you've tried making some work fun by using gamification and it has failed, there's one little thing you need to know:
The game won't work if the people aren't interested in doing the work in the first place.
But StackOverflow thrives! People dedicate hours a day answering questions, moderating and reviewing edits for free! Apparently people who become moderators get a T-shirt, as do those who cross 100K reputation. See the unicorn painting Jon Skeet of Google got when he crossed 200K.


Back to the 10million

If you tweet #SOreadytohelp or include it in your profile, you stand to get one of the 100 T-shirts (only?) that will be distributed to any random StackOverflow member over the next 4 weeks.


People are already excited...about the t-shirt....
Really? Excited about a t-shirt? Come on! 
How difficult would it be to create the StackOverflow logo in an image or icon editor, purchase a black t-shirt yourself and get the logo printed on it?
Apparently StackOverflow sends the selected person a Google Form where they an enter their address, and the t-shirt gets sent.

One would assume StackOverflow's funders would do something a bit more generous for its moderators and top contributors.
  • A little vacation to Hawaii perhaps?
  • or a meeting with some of the top celebrities in the programming world?
  • or a gift of some of the coolest gadgets the world knows of?
  • or a couple of adrenaline filled sky-diving jumps?
A 10 millionth celebration could've been that much cooler!

Anyway...keep up the good work, Joel and team!