about | help | code help+videos | done | prefs |
Write a program that produces the test data shown. The basic idea is that you are looking to see if the prime number 'prime' is ever a remainder of num/divisor for any divisor from 2 to num/2 inclusive. As preconditions you may assume that 'prime' is a prime number and that 'num'*2>='prime'. Look at the test data! test2022_12_08_HL_primeRemainders(51728, 4391) → "4391 IS a remainder of 51728 when divided by 15779." test2022_12_08_HL_primeRemainders(7528, 4391) → "4391 is NOT a remainder of 7528." test2022_12_08_HL_primeRemainders(45, 5) → "5 IS a remainder of 45 when divided by 8." ...Save, Compile, Run (ctrl-enter) |
Progress graphs:
Your progress graph for this problem
Random user progress graph for this problem
Random Epic Progress Graph
Difficulty: 290
Copyright Nick Parlante 2017 - privacy