Tech IndustryOct 3, 2019
Juniperhithere*

interview feedback review

I had a weird interviewing.io interview. Inspite of doing well(me thinks so), I wasnt given the headsup. This is how it went. 1) Was asked to code substr(haystack, needle) and this is the code i wrote in 8 minutes to write and test: def substr(haystack, needle): if len(needle) > len(haystack): return [] res = [] for i in range(len(haystack)-len(needle)+1): count = 0 for j in range(len(needle)): if haystack[i+j] != needle[j]: break else: count += 1 if count == len(needle): res.append(i) return res He pointed to me that I missed handling the "" string and None and "non-string" types as inputs. I told him that empty string should be handled, but pointed out the following: a) Usually in an interview, we dont check for null inputs, because, its always a oneline to handle it at the start of the code and in an interview, its not expected. b) I have never seen stuff being tested like, for a string input, is the given value is actually a string or not. Becasue this means, for every program i write: lets say a program that takes a list of numbers as input and a target number and does a binary search, My first line will be like if not all(isinstance(x, int) for x in arr) or not isinstance(target, int): return -1 I dont think this is expected in any interview and the interviewer was a bit too strict (may be crazy strict) to expect sometthing like this. He inisisted I handle all the cases, including wrong type as input and I did. His next question was to optimize the solution. I told him about KMP and explained the algorithm, but he wanted constant space. So i suggested Rabin Karp. And he wanted me to explain it and i explained. Then he wanted me to type in the editor the actual formula i would use to create hashes for the haystack = "aaab" and needles's lenght = 3. I wrote the detailed formulas and calculated the hashes for aaa and the rolling hash based on that for aab. It was exactly 30 minutes since the start of the interview, and he mentioned we have 3 minutes more and lets see how far you can go with the implementation. I told him, i cant do anything in 3 minutes, and asked him if this isn't a 45 minute or 1 hour interview. He said lets see your progress in 3 minutes. I decided to implement the rolling hash function (dint have the time to test it) and this is what i came up with in like 2 minutes: def calc_next_hash(phash, inp, i, size): phash -= inp[i-1] * (256 ** (size-1)) phash = phash * 256 phash += ord(inp[i+size-1]) return phash Then he ended the interview by giving 5 more minutes to ask questions. I made it a point to tell him that it was very really absurd, to do type checks for parameters in an interview. He said lets choose to disagree on this one and the interview ended. After the interview I was left a bit disappointed, should I be worried about interviewers like this one ?

Practice interviewing with engineers from top companies, anonymously.
Practice interviewing with engineers from top companies, anonymously.
interviewing.io
Add a comment
Microsoft djfjsk Oct 3, 2019

Was the interviewer's name Effulgent Slide Rule?

Juniper hithere* OP Oct 3, 2019

yes, yes, yes.

Microsoft djfjsk Oct 3, 2019

There are asshole interviewers like him everywhere. But most interviewers are good. Don't worry. You'll real interviews should be better.

Autodesk leetboba Oct 3, 2019

He gave me the same needle in the haystack question lol

Juniper hithere* OP Oct 3, 2019

Did you have a positive experience with him

Autodesk leetboba Oct 3, 2019

I didn't really have a problem with him

Microsoft make 💕 Oct 3, 2019

Well, based on what you described most likely he did not like your attitude and communication skills. I met inflexible people at work many times who are also super opinionated. It is always unpleasant to work with them (even in cases when they are right). You may not be such a person but you sure look like one of them based on your story.

Juniper hithere* OP Oct 3, 2019

How about the fact that i dint like his attitude in the first place and there are others like who posted below calling him the same.

Juniper hithere* OP Oct 3, 2019

Take some time to read the negative reviews people are posting on him.

Activision Blizzard d4567 Oct 3, 2019

Idk if your intent is just to give him constructive feedback on his interview but it sounds like you're being a dick. When someone asks you to handle null, it's an opportunity to discuss method design and talk about why public API methods need it but maybe not private ones. It's an opportunity to discuss throwing exceptions vs returning something. Or I guess an opportunity to sound overly sensitive about your code (huge red flag)

Juniper hithere* OP Oct 3, 2019

Null is fine. How about handling different input types? Will your first line of binary search code be an instance type check in an interview ?

Activision Blizzard d4567 Oct 3, 2019

TBH I don't interview in Python or JS so I never worry about type checking, but I think I'd rather discuss pros and cons then just do whatever the interviewer wants. One of the most common complaints about engineers is that they are too uncompromising in code review discussions. Imagine you two are co-workers and he gives you this feedback in a code review. You want to be very tactful and easy to work with if the difference is immaterial.

Activision Blizzard d4567 Oct 3, 2019

Also I don't think you should spend half of the interview coding a brute force solution then say "I can't finish that" when asked to code the faster one. You will be compared to candidates that had at least some working code for a fast solution. Get as far as you can. Also if you're aware that a solution is suboptimal consider not coding it at all (just describe and move on unless interviewer wants you to code that)

Juniper hithere* OP Oct 3, 2019

Well i spent 8 minutes coding and testing the brute force and he insisted on coding that first. Also the remaining time was spent on detailed explanation of KMP and Rabin karp using examples. Then he said 3 minutes left. It was a 30 minute interval in total.

Juniper hithere* OP Oct 3, 2019

And if you what Rabin karp is, you will be able to understand that calculating next hash is the core of the algorithm that i coded in a couple of minutes.

Apple whatup23 Oct 3, 2019

Don’t be so entitled, it was free practice, what did you expect? Go use pramp if you don’t like it

Juniper hithere* OP Oct 3, 2019

What ?? Free?? Yes, but its a practice that could potentially lead to a company screen to an onsite and offer and revenue for int.io. There is no such thing as a free lunch. U better start understanding that.

Apple std4hire Oct 5, 2019

It’s not your problem to worry about how int.io makes money. You aren’t even worried about int.io your post was about your bad experience and I’m telling you to suck it up

Juniper hithere* OP Oct 7, 2019

Well you may have sucked it up all your life. 🤣.. but that's not how everyone behaves...