changed twodigit function
changed twodigit function