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

 

srp4379@lausd.net quiz3 > divisibleBy5
prev  |  next  |  chance

boolean divisibleBy5(int num). A number is divisible by 5 if its last digit (the digit in the one's column) is 0 or 5. Or if when you divide it by 5, the remainder is zero. Return true if the number is divisible by 5, false if it's not.


divisibleBy5(1) → false
divisibleBy5(5) → true
divisibleBy5(7) → false

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

boolean divisibleBy5(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: 100

Copyright Nick Parlante 2017 - privacy