I want to go from that form $3^{n} \mod 7 $ to something that doesn't use exponent. it says, hint : you should use $ n \mod 7$
I listed the values from $3^0 \mod 7 $ to $ 3^{10} $
$$ 3^0 \mod 7 = 1\\ 3^1 \mod 7 = 3\\ 3^2 \mod 7 = 2\\ 3^3 \mod 7 = 6\\ 3^4 \mod 7 = 4\\ 3^5 \mod 7 = 5\\ 3^6 \mod 7 = 1\\ 3^7 \mod 7 = 3\\ 3^8 \mod 7 = 2\\ 3^9 \mod 7 = 6\\ 3^{10} \mod 7 = 4\\ $$
Then I want to find a way to get to the values with $n \mod 7$
I tryed with $ 3n \mod 7$ , $3 (n-1) \mod 7$ , Also tryed with the gcd(a,n) also tryed with something like $3(n * n) \mod 7$