Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
7
Task/Josephus-problem/BASIC/josephus-problem.basic
Normal file
7
Task/Josephus-problem/BASIC/josephus-problem.basic
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
10 N=41
|
||||
20 K=3
|
||||
30 M=0
|
||||
40 FOR I=M+1 TO N
|
||||
50 M=INT(I*((M+K)/I-INT((M+K)/I))+0.5)
|
||||
60 NEXT I
|
||||
70 PRINT "Survivor is number";M
|
||||
Loading…
Add table
Add a link
Reference in a new issue