For how many positive values of n are both n2 and 3n four-digit base 9 integers?
n2 is an integer implies n is even. The smallest four-digit base 9 integer is (1000)9, which is 93=729, but this is not even, so n2 is at least 729 + 1 = 730. This gives the lower bound n≥1460.
While n/2 is a four-digit base 9 integer, 3n cannot exceed the maximum value of four-digit base 9 integers. that value is (8888)9, which is 8(93+92+9+1)=6560, but it is not divisible by 3. That means 3n≤6558, i.e., n≤2186 is the upper bound.
To ensure that n/2 is an integer, the answer is the number of even numbers n in the range 1460≤n≤2186, i.e., 2186−14602+1=364.
n2 is an integer implies n is even. The smallest four-digit base 9 integer is (1000)9, which is 93=729, but this is not even, so n2 is at least 729 + 1 = 730. This gives the lower bound n≥1460.
While n/2 is a four-digit base 9 integer, 3n cannot exceed the maximum value of four-digit base 9 integers. that value is (8888)9, which is 8(93+92+9+1)=6560, but it is not divisible by 3. That means 3n≤6558, i.e., n≤2186 is the upper bound.
To ensure that n/2 is an integer, the answer is the number of even numbers n in the range 1460≤n≤2186, i.e., 2186−14602+1=364.