Epic Systems Interview Question
let initial height = h
1st day height = h;
2nd day height = 2h;
.
.
10th day height = 2^9 h;
given height on day 10 = 40
so,
2^9 h = 40 => h = 40 / 2^9;
we can write 40 = 2 x 2 x 2 x 5 = 2^3 x 5
so h = 2^3 x 5 / 2 ^9
h = 5 / 2^6
cross multiply both sides by 2^6
we get ,
2^6 h = 5 . Therefore, on 7th day height is 5 feet
suppose the initial height of the tree is a variable named "start"
- beyondfalcon March 24, 2010start*2^9=40
start*2^(n-1)=5
divide two equations, then 8=2^(10-n)
n=7