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

Home > Just Math
5-digit period (Posted on 2011-12-16) Difficulty: 3 of 5
What are two primes p > 0 for which 1/p has a purely periodic decimal expansion with a period 5 digits long?

Source: California math competition 2001

No Solution Yet Submitted by Ady TZIDON    
Rating: 4.0000 (3 votes)

Comments: ( Back to comment list | You must be logged in to post comments.)
Solution computer solution | Comment 2 of 3 |
   10   point 15
   20   P=2
   30   while P>0
   40    P=nxtprm(P)
   50    S=cutspc(str(1/P))
   60    if mid(S,3,5)=mid(S,8,5) then print P,S
   70   wend

run
Words for fractionals 15 (Decimals for display 72)
 3      0.333333333333333333333333333333333333333333333333333333333333333333333333
 41     0.024390243902439024390243902439024390243902439024390243902439024390243902
 271    0.0036900369003690036900369003690036900369003690036900369003690036900369 
 
Break in 60
?p
 59083543
OK

Interrupted while checking prime 59083543, the program had found 41 and 271. The 3 is an artifact of checking only that the numbers repeat every 5 digits from the decimal point without checking that the digits are different.


  Posted by Charlie on 2011-12-16 22:13:25
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 (11)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

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