Problem Here is the problem I am trying to solve.
The prime factors of 13195 are 5, 7, 13, 29. What is the largest prime factor of the number 600851475143?
def prime_calc():
num = raw_input("What is the number you want the primes for?")
prim_num = []
x = 2
while num/x > 1:
new_num = num / x
if num % x == 0:
return prim_num.append(x)
elif num % x != 0:
new_num = num/x += 1
return prim_num.append(x)
else:
break
I keep getting an invalid syntax error starting from the bottom up to the fourth line that doesnt like my "+=" operator