What is the smallest positive integer n for which n^2 is divisible by 18 and n^3 is divisible by 640?
a=1; c=a^2;b=a^3; if(c%18==0 and b%640==0, goto4, goto5);printc, a; a++;if(a<1000, goto1, 0)
The smallest n = 120
What is the smallest positive integer n for which n^2 is divisible by 18 and n^3 is divisible by 640?
n^2 is divisible by 18
18=2*2*3
n must have factors 2 and 3
and
n^3 is divisible by 640
640=5*2^7
n must have factors 2*2*2*5
Put these together and n must have factors 2*2*2*3*5 = 120 That is the smallest possible value of n