Let the three terms be ra,a,ar.
Their product is 1:
ra⋅a⋅ar=a3=1
So a=1, the only real cube root of 1.
Their sum is 1039:
r1+1+r=1039
Multiply both sides by 10r:
10+10r+10r2=39r
10r2−29r+10=0
10r2−25r−4r+10=0
5r(2r−5)−2(2r−5)=0
(5r−2)(2r−5)=0
So r=52 or r=25.
When r=52, the terms ra,a,ar are 25,1,52.
When r=25, the terms ra,a,ar are 52,1,25.
Hence, the common ratio is 52 with terms 25,1,52, or the common ratio is 25 with terms 52,1,25.