You have a single branch of a GIT or SVN repository. At some commit number G, the code in the repo worked (G = good commit). At a later commit number B, you noticed that the code was broken (B = bad). The code may have become broken anytime at or before B, but after G. B was just the first time that you noticed the code was broken. Both G and B are positive integers and G < B. You have access to a function.......bool isCommitGood(integer)......... that takes a commit number and tells you whether the code at that commit worked or was broken. Write code to find the most recent working commit (i.e., the number/index of the last good commit before the code became broken).
Software Engineering Interview Questions
56,373 software engineering interview questions shared by candidates
In a situation where you have to choose quality over quantity, which is most important?
If you had an assignment that required you to ride a unicycle while juggling, what would you do to acquire these skills?
The abstract class question was posed differently- he said something along the lines of "Suppose you have an interface in which certain aspects of the implementation could be defined and those would carry over to classes implementing it- when do you think that would be useful?" ."
You realize the learning curve will be very steep?
I was asked a puzzle .. You have 12 balls identical in size and appearance but 1 is an odd weight (could be either light or heavy). You have a set of scales (balance) which will give 3 possible readings: Left = Right, Left > Right or Left < Right (ie Left and Right have equal weight, Left is Heavier, or Left is Lighter). You have only 3 chances to weigh the balls in any combination using the scales. Determine which ball is the odd one and if it's heavier or lighter than the rest. How do you do it?
How to design a system which tells about movies going on each zip codes along with their showtimes and theatres
Longest substring
when a method containing below code will result in try{ throws exp1}catch(Exception e){throws exp2} finally{return a}
how to find result of last executed command on linux
Viewing 741 - 750 interview questions