Fixed tail recursion
Added CSE