id/email
password
forgot password
create account
about | help | code help+videos | done | prefs
CodingBat code practice

scottm@cs.utexas.edu cs305j-set4 > lastDigit
prev  |  next  |  chance

Given two non-negative int values, return true if they have the same last digit, such as with 27 and 57. Note that the % "mod" operator computes remainders, so 17 % 10 is 7.

lastDigit(7, 17) → true
lastDigit(6, 17) → false
lastDigit(3, 113) → true

...Save, Compile, Run         


Show output only (no red/green)

prev  |  next  |  chance   |  CodingBat  >  scottm@cs.utexas.edu cs305j-set4

Forget It! -- delete my code for this problem

Progress graphs, just for fun:
 Your progress graph for this problem
 Random user progress graph for this problem
 Random Epic Progress Graph

Code Help and Videos

Misc Code Practice

184.0

Copyright Nick Parlante 2006-11 - privacy