Optimal Binary Search Tree using Dynamic Programming