Dear interviewers, please stop expecting the code to pass test cases

Oct 15, 2021 21 Comments

I am interviewing for quite some time now. I came across many interviews where the interviewer doesn't necessarily care about the code. They of course want to make sure that the algorithm is efficient, but the criteria for pass/fail is binary. They will give you bunch of test cases and will expect the code to pass all the tests. Even if they agree that the algorithm is correct, if the code doesn't pass the tests, I get rejection. If passing the test cases is the criteria, give us HackerRanks. Why waste everyone's time?

Please stop doing that. In the day to day job, there are multiple sources which we can use to modify our code. We are not nervous all the time (the way we are in interview setting). We can take help from teammates. Even after that there are bugs in every single code. Then it really doesn't make sense for you to ask the candidate to run the code and check if all tests pass or not.

Yoe: 5
TC: $200k

comments

Want to comment? LOG IN or SIGN UP
TOP 21 Comments
  • Dear interviewees, please stop expecting to pass the interviews.
    Oct 15, 2021 1
  • Google
    fNbb82

    Go to company page Google

    fNbb82
    LOL. Let’s picture this in a practical setting. Would you send code out for review (or even push it in) with a few test cases missing? I wouldn’t mind minor syntax errors, but missing critical test scenarios is scary.
    Oct 15, 2021 7
    • Google
      fNbb82

      Go to company page Google

      fNbb82
      Most interviewers ask questions they know from what I can tell. There’s some room for improvement sure. OPs concern is more about missing test cases being the cause for disqualification which I believe is fair since it’s not a solution if it’s failing to meet all test scenarios. No one would want to work with someone who introduces obvious bugs.
      Oct 16, 2021
    • New
      pJvh01

      New

      pJvh01
      True, I think it depends on how you interpret the OP's concern

      If test cases fail because of missing/erroneous logic, then yea that should be negatively judged

      If the logic seems sound but tests are failing due to coding errors/bugs and neither the interviewee or interviewer easily figure it out in time, I think more leeway should be given
      Oct 16, 2021
  • Amazon
    cidnxi

    Go to company page Amazon

    cidnxi
    You know what, everyone can get the correct and best algorithm for the questions. So, who will they hire, you or the person who coded the exact leetcode solution and passed all the test cases? So stop whining and start mugging up the leetcode.
    Oct 15, 2021 3
    • Amazon
      cidnxi

      Go to company page Amazon

      cidnxi
      Haha...you are outdated then. Just try an interview with any company right now and you'll realize this when a 1 yoe college graduate will ask two med/hard LC within 40 mins.

      You might not get impressed but that's the only way you can get a big fat TC.
      Oct 15, 2021
    • PayPal
      checkedOut

      Go to company page PayPal

      checkedOut
      Not really, but I do think it's time to change interview styles.

      Because LC is bringing almost only one type of person. People who don't understand data structures well enough to only do 20-50 problems then logically solve anything else that gets thrown their way
      Oct 15, 2021
  • NVIDIA
    wishe-jags

    Go to company page NVIDIA

    wishe-jags
    I guess code doesn’t need to work anymore
    Oct 15, 2021 0
  • Hulu
    YellowPalm

    Go to company page Hulu

    YellowPalm
    If your code can't pass the test cases, then your code is failure. Therefore, your interview.
    Oct 15, 2021 0