Let x² be the largest six-digit perfect square.
The largest six-digit number is 999,999, so
x² ≤ 999,999.
You know that 1,000² = 1,000,000, which is only 1 more than 999,999, so x² must be the next smaller square, which is (1,000 - 1)².
(1,000 - 1)² = 999² = 998,001.