Skip to content

Instantly share code, notes, and snippets.

@mcnole25
Created March 18, 2025 01:28
Show Gist options
  • Save mcnole25/fe850377cb38bf39a3e451f5b19e569d to your computer and use it in GitHub Desktop.
Save mcnole25/fe850377cb38bf39a3e451f5b19e569d to your computer and use it in GitHub Desktop.
Table for period length of final digits for k^n.

Consider the sequence formed by the final decimal digits of kn. What is the period length? The table is shown below.

Example: the final digit of 2x cycles {2, 4, 8, 6, 2, 4, 8, 6, 2, 4, 8, 6...} giving it a period length of 4.

Final 2n 3n 4n 5n 6n 7n 8n 9n
1 4 4 2 1 1 4 4 2
2 20 20 10 1 5 4 20 10
3 100 100 50 2 25 20 100 50
4 500 500 250 4 125 100 500 250
5 2500 5000 1250 8 625 500 2500 2500
6 12500 50000 6250 16 3125 5000 12500 25000
7 62500 500000 31250 32 15625 50000 62500 250000
8 312500 5000000 156250 64 78125 500000 312500 2500000
9 1562500 50000000 781250 128 390625 5000000 1562500 25000000
10 7812500 500000000 3906250 256 1953125 50000000 7812500 250000000
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment