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

 

pais@kinetigram.com > L45_nearTen
prev  |  next  |  chance

APCS Logic 4, Problem 5. Given a non-negative number "num", return true if num is within 2 of a multiple of 10. Note: (a % b) is the remainder of dividing a by b, so (7 % 5) is 2.


L45_nearTen(12) → true
L45_nearTen(17) → false
L45_nearTen(19) → true

...Save, Compile, Run (ctrl-enter)

public boolean L45_nearTen(int num) { }

Editor font size %:
Shorter output


Forget It! -- delete my code for this problem

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

Java Help

Misc Code Practice

Difficulty: 200

Copyright Nick Parlante 2017 - privacy