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

 

orion.a.smith@gmail.com apcsa-primitives > apcsaPrimitivesLargerBySmaller
prev  |  next  |  chance

Given two numbers, find out whether the larger of the two numbers is divisible by the smaller of the two numbers (meaning that the remainder, after dividing the larger number by the smaller number, is zero). Either of the two numbers could be larger. Precondition: both numbers will be positive and the two numbers will be different.


apcsaPrimitivesLargerBySmaller(5, 3) → false
apcsaPrimitivesLargerBySmaller(15, 3) → true
apcsaPrimitivesLargerBySmaller(3, 15) → true

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

public boolean apcsaPrimitivesLargerBySmaller(int a, int b) { }

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