Project Euler 274 - Divisibility Multipliers

Official link: https://projecteuler.net/problem=274

Thought Process

This problem was very easy for a 65% difficulty problem.

If p = 3, m = 1, if p = 7, m = 5 by inspection,

Because p ≠ 2 or 5, the multiplicative inverse is guaranteed to exist, therefore we can just using python pow function!

Generate all primes up to 10^7, using my prime generator and then for each prime, p, add pow(10, -1, p) to a total

Interactive Code

Input an integer (yourinput)

Code will output all the sum of the divisibility multipliers for the primes that are coprime to 10 and less than yourinput?