The Student Room Group

Awkward programming job interview?

I went to this programming job interview and I had to do one of those programming test questions that development companies love doing so much.

There were 3 papers, each had a programming question. As I was doing the second paper, some guy came in without introducing himself and asked if I'd finished. I said I'd finished the first paper and he took the paper; he said that there's nothing wrong with my answer, but he said that he wanted the algorithm to be in one line instead of multiple lines.
Well, the thing is, the test question didn't even ask for an optimised solution (i.e. the one line algorithm); it was just creating a program to do X, Y and Z. :erm:
I wasn't able to make my algorithm into just a single line algorithm since I was pressing for time (and I already had invested the time to create the current algorithm) and I needed to finish the other questions. The final question was about a sorting algorithm. Since I haven't done sorting for years, I couldn't really create the algorithm properly, but I was able to finish the whole questions.

The guy came in again and looked at my paper. He said that I didn't get what he wanted (which was the single line algorithm, the one that was never asked on paper in the first place). He also asked me about the algorithm that I wrote.
I got a First for my computing degree, and he subtly said that even First class degree holders sometimes can't answer the questions the company gave them (which I think was a subtle hint of his criticism towards me : /). As he was saying this, he was rolling my degree transcripts and my answer sheets (like a scroll) in front of me : /

At the end, after we finished with the interview, he said the interview was done and walked away without shaking my hand or even saying thank you or anything.

Awkward? Did I even deserve this? I would think it wasn't even professional : /
Reply 1
No, you did not. Also writing algorithm in one line instead of multiple lines is bad practice. Do write more lines but make code readable to human beings.

Be happy. You don't want to work for such arrogant people. Find a place elsewhere. Also who the hell creates their own sorting algorithms these days? There are well-tested libraries in every language to use and you won't write better sort in several minutes than hundreds of thousands of people already did.

Of course it is important to show that you can create algorithms but ... it is still strange. Some interviews are full of crap because instead of testing on what is in your job, they test on some obscure concepts and other crap unrelated to your job role. Also creating algorithms in a half hour is strange checking. Firstly, you will have more time on your job role, secondly, you will not feel stressed.

You should tell him that you simply write code which is readable. It is a great skill and other programmers in a team will not be forced to yell 'WTF' when seeing your code.

In other words, find another place to work and practice stuff you don't know. You've been asked about sorting. Go and refresh your knowledge.
Reply 2
Original post by Valentas
No, you did not. Also writing algorithm in one line instead of multiple lines is bad practice. Do write more lines but make code readable to human beings.

Be happy. You don't want to work for such arrogant people. Find a place elsewhere. Also who the hell creates their own sorting algorithms these days? There are well-tested libraries in every language to use and you won't write better sort in several minutes than hundreds of thousands of people already did.

Of course it is important to show that you can create algorithms but ... it is still strange. Some interviews are full of crap because instead of testing on what is in your job, they test on some obscure concepts and other crap unrelated to your job role. Also creating algorithms in a half hour is strange checking. Firstly, you will have more time on your job role, secondly, you will not feel stressed.

You should tell him that you simply write code which is readable. It is a great skill and other programmers in a team will not be forced to yell 'WTF' when seeing your code.

In other words, find another place to work and practice stuff you don't know. You've been asked about sorting. Go and refresh your knowledge.


I was thinking the same as well! :eek: It's not necessarily that you'd get a better algorithm from the line number lol.

Based on the interviewer himself, I had a vibe that the company may be full of pretentious snobs that think highly of themselves (it's rather a large company). Would be tremendously draining working with such nonsense really.

I completely agree.
I was working with this company before and they asked this particular "so brilliant" employee to create the test questions for future candidates; being the young and painfully narrow minded person that she is, she took a puzzle book and decided to take the questions from the book and use them as test questions. Most of the test questions were so obscure that I wondered what was the actual motivation doing it in the first place; I had a feeling that they were just playing to superiority game (who's smarter than who and who's not :erm:

I actually wanted to tell him that but I got so flustered (and was quite annoyed) that I didn't bother myself to tell him. There was a moment that I actually just wanted to walk out from the interview because he was just so damned rude and patronizing.

Lastly, you know what's just so great? The guy was either younger or the same age as me :mad:
Was the guy Asian?

Posted from TSR Mobile
Reply 4
Sometimes a 1 liner is all you need :holmes:
Reply 5
Be glad you were spared from working for a guy like that. He sounds awful.

As said above, unnecessarily condensing code hampers its readability. Write it in simple steps; let the compiler do optimisation beyond that.
Reply 6
Original post by QuantumSuicide
Was the guy Asian?

Posted from TSR Mobile


He's Chinese.
Wait, does that matter? lol.

A mate of mine said it does :teehee:

Original post by miser
Be glad you were spared from working for a guy like that. He sounds awful.

As said above, unnecessarily condensing code hampers its readability. Write it in simple steps; let the compiler do optimisation beyond that.


Absolutely. He's a joke.

It took me a while to write the algorithm; imagine my horror that he wanted it in a single line, after I'd already written my own algorithm :pinch:
(edited 10 years ago)
Reply 7
Well if he was Chinese you'll know to bring dim sums for the 2nd interview.

Yummy!
Reply 8
Was like this interview I had for a dev department in a local college, the guy was sat really close to me and kept leaning forward, raising his voice and asking questions, then probing all of my answers (asking a question based on my answer) then he says somthing like

"the way I see it, i.t. jobs dont finish when you walk through the door at 5pm, its all about staying on top of the latest technologies and updates, if you dont like that then frankly you're in the wrong career *weird laugh*

which I sort of agree with but he looked wrecked as hell, if his job/workplace is that stressful I dont want in there lol.
what kind of algorithms did you have to write?
Reply 10
Original post by UniMastermindBOSS
what kind of algorithms did you have to write?


I wanted to write this initially but I think I'd keep this private (for obvious reasons)
Reply 11
Original post by kka25
I wanted to write this initially but I think I'd keep this private (for obvious reasons)


Obviously not that obvious.
Original post by kka25
I wanted to write this initially but I think I'd keep this private (for obvious reasons)

Well it is quite possible you deserved it is he asked you to print "hello world." tell us what the program is so we can commit a fair judgement
Reply 13
Original post by Dominic101
Well it is quite possible you deserved it is he asked you to print "hello world." tell us what the program is so we can commit a fair judgement


Obviously not. He was asking me to do some computations based on a particular mathematical theorem, which he wanted in one line.

Ironically my previous other interview asked me to write a "Hello world" program using structures. The tricky part is they wanted it in C programming and the "Hello world" string (array of char) to be inserted by the user and captured by the structure. Pretty easy if you know pointers and structures (in C); complicated if you have never been exposed to C :wink:
(edited 10 years ago)
Reply 14
Did you not say anything to him?
Well, it seems that he was a bit rude. But at the end of the day he's in charge of recruiting or not recruiting you so.. there's not much point complaining about it.

Also, the job I've got now, I currently don't have a degree but I still had to pass an interview test; and the recruitment company told me before I went that many people with computing / computer science / software engineering degrees couldn't pass the test; so I totally see where he's coming from when he said even people with firsts can't do it. At the end of the day a degree shows more that you know about theories than it does practical competence. The best combination is a degree and experience; which is why I'm going to University this year.

Don't be disheartened but I don't think he was meaning to be as rude as he may have come across.

Quick Reply

Latest

Trending

Trending