# Primes and perfect square on numbers

I have two equations, which may play an important role in my further studies on theory of numbers.

1) How many pairs of (A, B, x) we can make in $A^x + B ^x = prime$? Here $x$ is $> 2$ and A, B are positive integers.

2) can we find a number(s) with one hundred 0′s, one hundred 1′s and one hundred 2′s be a perfect square. If yes, what is that number or otherwise how to disprove it about such number does not existence?

-
clearly we must have $x=2^n$ or else the sum will be divisible by $A+B$ – Konstantinos Gaitanas Dec 8 '13 at 13:12
clearly not. $2^2+3^2=14$ which is not divisible by 5 – Thomas Dec 8 '13 at 13:17
@KonstantinosGaitanas and @Thomas! $1^4 + 2^4 = 17$. Here $x = 4 >2$ and A = 1, B = 2 are positive integers. The result 17 is prime. Like this how many A, B and x are existing? can you list? – narosanair Dec 8 '13 at 13:20
@Thomas clearly yes.$x>2$ – Konstantinos Gaitanas Dec 8 '13 at 13:21
Thank you for understanding me. can you list such pairs please... also look my second question of this post. – narosanair Dec 8 '13 at 13:25

The number you want is $222\cdots 111\cdots 000\cdots$ which is divisible by $3$ (because the sum of its digits is $2\cdot 100+1\cdot 100+0\cdot 100=300$ divisible by $3$)
But,it is not divisible by $9$ (because also the sum of its digits is not)
! Sir, in my first question, you told that, x must be $2^n$ or else the sume will be divisible by $A + B$. Can you prove your argument mathematically? Please.. – narosanair Dec 8 '13 at 14:45
If $x$ is not a power of $2$ it must have an odd factor say $d$. Then $x=k\cdot d$Then $A^x+B^x=(A^k)^d+(B^k)^d=(A^k+B^k)((A^k)^{d-1}-(A^k)^{d-2}\cdot B+\cdots +(B^k)^{d-1})$ which is a multiple of $A^k+B^k$.Don't you know the identity $a^n+b^n$ for odd $n$? – Konstantinos Gaitanas Dec 8 '13 at 15:00