added new file digit.r