Thursday, April 26, 2012

interview questions

Not so big company which focused on software development for controllers (arm without MMU - cortex-m series) for uclinux

Like interview like this. At first we had talk about company, about tasks of software developers there. After that we had talk about my experience. And at the end they ask me to ask several questions.

1) How many dotes will be printed (stdout flush after every printf(), if you notice this it'll be good, because if stdout is't flushed result may be unexpected)
for(i=0; i<10; i++) {
     printf(".");
     fork();
}

2) Propose algorithm the reverse string without additional memory, except additional memory (you can ask for constant amount of memory before you get a string - before you will know size of biggest word)
Example
My name is Alex -> Alex is my name

3) Propose algorithm to check if linked list has cycle.
it's very popular question on interviews.


No comments:

Post a Comment