Placement Papers - Protechsoft

Protechsoft Technologies Pvt. Ltd.
Protechhsoft Technologies Interview Experience - Chennai, October 07, 2011
Posted by :
Javed Sheriff
(0)
Hi friends,

I'm Javed (CSE dept) from AMS College of Engineering. I would like to contribute my experience with Protechsoft Technologies which had come to our college for campus recruitment. It is mostly said that this company handpicks a very small number of students who have shear knowledge in programming with C language.

You can say out of a scale of 150 students only around 2 or 3 might get placed. Well to begin with the following is the procedure of how the company shortlists the students.

Round 1 - Written Programs in C (not objective but on the spot hand written ones). Time limit - 45 mins.

Question 1 - Write a C program to convert an integer value to a hexadecimal value by using pointers as string manipulations.
Question 2 - Write the C function equivalent to strncmp() library function.
Question 3 - Write a C function which is equivalent to creating a string from which a substring can be taken out as per need and displayed (use pointers).
Question 4 - Write a C program to find out the 531st bit in the following function char [1035].
Question 5 - Write a menu driven program to depict a table like structure to be implemented in a database which would consist of name, age, phone no and company name such that after each entry the row increments by one for the next n values.

Note: They mainly emphasize on the pointer concept. So you have to be very strong at that if not in any thing else.

Questions were indeed tough. And we had no idea of what to do. I remembered the basic conversion strategy for integer conversion to hexadecimal. I wrote a program on that and as said I used initialization of pointers for string manipulation although not sure about the accuracy of my program.

For the second one we needed only to write a c function, which I wrote.

For the third one, although they had asked for a c function I thought of writing a program on it. Started with the basic main() function program as we all know which had initializations and a parametric value call to my int substring() function. After the main() program I wrote the code for the substring library function and incremented my input data values for main string as well as for my substring (post increment only).

The remaining two were very confusing. So I just skipped it.
The results were to be announced in 2 hours. Of which just 10 members were selected for the next round i.e., the Technical HR round. Fortunately, my name was on that list. I was called for the HR round.

The HR had the paper in his hand which I had written for the first test. He examined my programs and asked if I can do anything to optimize my first program. I suggested him about looping. He nodded. And finally he himself wrote a code which could be optimum for my original program.

He then asked me to implement the C function this time for strcpy().
Then he wrote the following code:

struct s
{
int a=100;
char d=axe;
}

struct s.a;
struct s.d;

printf ("%d", s.a) ;

He asked me the output of the above program. I said 100. He nodded in agreement and changed the "struct" part to "union" part and asked me the output this time. I said I didn't knew.

He then asked me the general difference between structures and unions. I told.

Difference between arrays and linked lists, which is more superior? I told.
He then asked me to wait outside for the result.