PDA

View Full Version : Lulz at my desk :]



Hackuin
07-29-2011, 06:01 PM
Yesterday, we had an issue with processing some dump files.
We had 8 TELECOM COMPANY TOWER ***** of different six different locations.
And you might guess, TOWER *****, these each telecom TOWER dump contains, 20000+ IMEI, IMSI NUMBERS.

We need to get the most common/similar IMEI numbers on these six locations.
So, basically, we need to take a one IMEI number of one TELE-SERVICE PROVIDER and compare that IMEI number with other IMEI numbers on those different locations. Manually, doing so, is like dumbest thing you would ever do with a machine.

I just kept my cool, and kept quite, watching, other people using excel, some formula etc., I slowly went to my machine, and wrote a simple bash script.
And, I had a solution, but these people, pew!! "trying hard" Lolz..



#!/bin/bash
cat $1 | while read LINE; do
cat $2 |grep $LINE >> $3
done


After few hours, I asked them, I can just do it in few minutes, And, showed them, my code, and they were like shocking state, the actual problem is, default tools, on Linux and or windows, like merge, will show you the differences in the files, not similar words/etc., and, someone asked me, what programing language is that, I said, ask "BASH".

However, someone came down and said, he had written a vb application, with some buttons and window as you could guess, but, I said, its done. And, appreciated his effort and told him, I not much worried about interface/outlook of the applications or etc.. we were just need the RESULT. And, I had it will hell lot of lesser code.

-Hackuin

prashant_uniyal
07-29-2011, 06:38 PM
Nice share!! +1 that result matters a lot than a fancy GUI :)