not getting the right result