void CopyString(char *From, char *To) { /* Fill this in */ } The only correct answer to this interview question is "No."
The four programming questions from my 1994 Microsoft internship interview (2023)
11–20 of 103 posts
Re: The four programming questions from my 1994 Microsoft internship interview (2023)
#12The circle outlining one seems interesting to me. I definitely didn't read the algorithm ahead of time, and I'm probably not as smart as a revolutionary genius computer scientist, but I thought of 2 basic algorithms in a few minutes. You could iterate over the degrees 0 to 360, use trig functions to figure out where the point at that angle is, and plot the closest point. Might need to be a bit tricky about the step s…
Re: The four programming questions from my 1994 Microsoft internship interview (2023)
#13It's pretty amazing to me that, if your goal is to check that the intern candidate can write plain C, the questions still look pretty reasonable to me even in 2026, maybe except for the question related to colors which will probably confuse the majority of the interns (2 bits per color? how is that possible). For the circle drawing exercise, it just seems that the interviewer did not do a good job hinting the author.…
It seems the first two questions are coding ones, and the second two ("flood fill" and circle drawing) are more thinking ones. The flood fill color detection one would be fastest with a look up table returning a bitmask of colors contained in the byte, with the Color param also as a bitmask, then the result is just lut[Pixel] & Color. The circle drawing one only needs you to know basic trig to get from radius and ang…
Re: The four programming questions from my 1994 Microsoft internship interview (2023)
#14It's pretty amazing to me that, if your goal is to check that the intern candidate can write plain C, the questions still look pretty reasonable to me even in 2026, maybe except for the question related to colors which will probably confuse the majority of the interns (2 bits per color? how is that possible). For the circle drawing exercise, it just seems that the interviewer did not do a good job hinting the author.…
> (2 bits per color? how is that possible) Assuming high colour depth, yes, but wouldn’t it have been specified as part of the question that ‘this was for four-color CGA mode’? I think 2 bits per colour for 4 colours total seem pretty sensible even in 2026. :-)
Re: The four programming questions from my 1994 Microsoft internship interview (2023)
#15It's pretty amazing to me that, if your goal is to check that the intern candidate can write plain C, the questions still look pretty reasonable to me even in 2026, maybe except for the question related to colors which will probably confuse the majority of the interns (2 bits per color? how is that possible). For the circle drawing exercise, it just seems that the interviewer did not do a good job hinting the author.…
It seems the first two questions are coding ones, and the second two ("flood fill" and circle drawing) are more thinking ones. The flood fill color detection one would be fastest with a look up table returning a bitmask of colors contained in the byte, with the Color param also as a bitmask, then the result is just lut[Pixel] & Color. The circle drawing one only needs you to know basic trig to get from radius and ang…
Re: The four programming questions from my 1994 Microsoft internship interview (2023)
#16Earlier quoted context omitted.
It seems the first two questions are coding ones, and the second two ("flood fill" and circle drawing) are more thinking ones. The flood fill color detection one would be fastest with a look up table returning a bitmask of colors contained in the byte, with the Color param also as a bitmask, then the result is just lut[Pixel] & Color. The circle drawing one only needs you to know basic trig to get from radius and ang…
The circle one is fishing for sonething clever. 90s without floats means no trig
As the author notes, it would certainly be a massive ramping up in difficulty if they were expecting you to reinvent the midpoint algorithm on the spot.
Re: The four programming questions from my 1994 Microsoft internship interview (2023)
#17void CopyString(char *From, char *To) { /* Fill this in */ } The only correct answer to this interview question is "No."
Hey, in 2026 strcpy is still part of the C standard library (much to the chagrin of anyone security conscious).
Re: The four programming questions from my 1994 Microsoft internship interview (2023)
#18The circle outlining one seems interesting to me. I definitely didn't read the algorithm ahead of time, and I'm probably not as smart as a revolutionary genius computer scientist, but I thought of 2 basic algorithms in a few minutes. You could iterate over the degrees 0 to 360, use trig functions to figure out where the point at that angle is, and plot the closest point. Might need to be a bit tricky about the step s…