Programmer interview questions shared by candidates
You are given two rope of equal length and a lighter. If you light a rope at one end, it takes an hour for it to completely burn, but it does not burn at a constant rate. For example, the first quarter of the rope might take 50 mins to burn and the remaining three quarters might only take 10 mins. Using this knowledge, how would you figure out when 45 mins have passed.
If you light a rope at both ends, it takes 30 mins for it to completely burn. So you light one rope at both ends and the other rope at one end,. After 30 mins, rope one is completely burnt and rope two has 30 mins of burning left. Light the other end of rope two and it will take 15 mins to finish burning.
Use the cell phone