thank you oliver. date api's 2nd parameter is 0 based