fn called with input fn called with input fn called with input fn2 called with fn output fn2 called with fn output fn2 called with fn output elseFn called with fn2 output fn called with fn2 output done called with fn2 output done called with else output fn2 called with fn output elseFn called with fn2 output done called with else output