All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars    
perplexus dot info

Home > Just Math
Ninety Seven and Divisibility Nuance (Posted on 2021-12-12) Difficulty: 2 of 5
Determine the minimum value of a positive integer N such that:
o N has the form: 97.......97, and:
o N is divisible by 99

No Solution Yet Submitted by K Sengupta    
Rating: 4.0000 (1 votes)

Comments: ( Back to comment list | You must be logged in to post comments.)
re(4): solution | Comment 8 of 10 |
(In reply to re(3): solution by H M)

You have indeed uncovered a bug in the program. After testing 97997, the next number tested was 971097, which indeed skips over ever even testing 970497 for divisibility by 99. This results from incrementing the latter part of the number from 997 to 1097, and increasing the front part to 970000 to accommodate the now 4-digit end part.


I was trying to avoid the overhead of character formats, but introduced this bug in the process. Accounting for leading zeros in the mid part is a problem also. Just forming the numbers to be tested is more complex than it would seem.

  Posted by Charlie on 2021-12-12 18:07:46
Please log in:
Login:
Password:
Remember me:
Sign up! | Forgot password


Search:
Search body:
Forums (0)
Newest Problems
Random Problem
FAQ | About This Site
Site Statistics
New Comments (13)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

Chatterbox:
Copyright © 2002 - 2024 by Animus Pactum Consulting. All rights reserved. Privacy Information