Teradata Interview Question

write an algorithm to determine if an integer given is prime, write an efficient and inefficient implementation of the algorithm.

Interview Answers

Anonymous

Jul 13, 2018

so the most efficient way we know about doing this is to check all numbers less than squareroot of half the integer in question and see if any number less than it is a factor. and the inefficient way i only halved it without considering the squareroot.

Anonymous

Mar 1, 2021

In these sorts of interviews you really need to drill down and understand what the interviewer is looking for. A good way to simulate a real interview experience is to do a mock with one of the Teradata Software Engineering experts on Prepfully, rated super strongly on TrustPilot... prepfully.com/practice-interviews