Bellman example not working