+0  
 
0
750
4
avatar

John counts up from 1 to 13, and then immediately counts down again to 1, and then back up to 13, and so on, alternately counting up and down: What is the 1000th integer in his list?

 Dec 14, 2020
 #1
avatar
+1

I got 9

 

This might be a bit cheaty but i made a program do it

 

 

https://onlinegdb.com/_Xa6EYxOCj

 Dec 14, 2020
 #2
avatar
0

Actually, I messed up the program:
Heres the new one https://onlinegdb.com/40uQViuJZ

I get 10

 

idk tho

Guest Dec 14, 2020
 #3
avatar+128075 
+2

Let's see if we  can  find a pattern   ......

 

 

1    2     3    4   5    6    7   8    9   10 

11  12  13  12  11  10   9   8    7    6

5    4     3    2    1   2    3   4    5     6

7    8     9   10  11  12  13  12 11  10

9    8     7   6     5   4    3    2    1    2

3    4     5    6    7   8    9  10   11   12

13 12   11  10  9    8    7    6    5     4

3    2     1   2    3    4    5   6    7     8

9   10   11  12  13  12  11 10  9     8

7    6     5   4    3    2    1    2   3     4

5    6     7   8    9   10   11  12 13   11

10  9    8   7    6    5      4   3    2     1

2   3    4    5    6    7     8    9   10   11

12 13 12  11  10   9     8    7   6     5

4   3    2     1  2     3    4    5    6     7

8  9   10   11  12  13   12  11  10   9

8  7    6     5   4     3     2    1   2    3

4   5   6     7    8   9    10  11  12   13

12  11  10    9  8   7     6   5   4    3

2    1    2    3   4   5  6  7  8   9

10  11  12  13   12  11   10  9  8 7

6   5    4     3    2   1   2   3  4   5

6   7   8  9  10  11  12  13  12 11

10  9   8  7   6  5  4   3   2    1

 

The pattern repeats  after  every  120   digit

 

1000  mod 120    =   40

 

The 1000th digit  is   9

 

 

cool cool cool

 Dec 14, 2020
 #4
avatar
+1

Ah yeah you're right there was a messup in my second program

Guest Dec 14, 2020

5 Online Users

avatar