$\begin{aligned} 144 &= 12^2 \\ 1444 &= 38^2 \end{aligned}$
Are there any other numbers $144 \ldots 44$ (starting with 1 and followed by all 4s) that are perfect squares?
This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try
refreshing the page, (b) enabling javascript if it is disabled on your browser and,
finally, (c)
loading the
nonjavascript version of this page
. We're sorry about the hassle.
Why can you factor out $16$ ? $144\dots44$ isn't divisible by $16$ for $n\ge3$ .
Log in to reply
Oh, I'm sorry, that's a mistake. I meant to say $4$ .
12012^2 = 144288144, which starts with 144 and ends on 44. So I'm not wrong :/. The answer is 'Yes'.
Log in to reply
The dots were meant to say that there are a bunch of $4$ s in between. I'm sorry for the confusion.
Log in to reply
But it literaly says: "starting with 144... and ending in ...44" thats what I understand then. I also got confused.
@Henry U , you could say "(an integer that exists of a 1 followed by four or more 4's)"
Log in to reply
@Carlo Wood – That's a better wording, thank you. Somehow, I can't edit the problem, so @Calvin Lin, could you replace the part in brackets by "a 1 followed by at least 4 4's"?. Thanks!
the answer 'no' is clearly wrong. the mistake in this problem is not in the question, but in the answer. the meaning of the question is unmistakable  starts w 144, ends in 44. says nothing about the middle, which means 'whatever'. any number that starts with 12 pr 38 has enough zeroes in between and ends with 12 or 38 will fit the bill. so, the only correct answer is yes
Log in to reply
Then we have a horse of a different colour. In setting questions detail, accuracy, and lack of ambiguity are everything!!
What should the number of digits of 144...44 be in the solution?
Log in to reply
The question is just whether there is a number with any number of 4's that is a perfect square.
So what about 12012^? Starts with 144 and ends with 44? This is a solution or have I missed something here
Log in to reply
Sorry Carlo just noticed you came to same solution! There another one 38038 !! Starts with 144 and ends with 44!!
Well done finding that number, but the problem asks about numbers which have only the initial 1 followed by 4’s. Your number is 144288144, which is close, but the question is interested in numbers like 144444444.
Log in to reply
He commemted that before I had changed the wording because it was very ambigous before that.
if you can factor a 4 out of the sum the remainder modulo 4 should be zero
Log in to reply
The remainder of the number $1\underbrace{444\ldots444}_{n \text{ } 4\text{'s}}$ is indeed $0$ because it ends in $44$ which is divisible by $4$ . At the end, where I mentioned the remainder $\pmod 4$ , I was referring to the number $1 \underbrace {444\ldots444}_{n \text{ } 4\text{'s}} \div 4 = 36\underbrace{111\ldots111}_{(n2) \text{ } 1\text{'s}}$ . which leaves a remainder $3 \pmod 4$ .
Perfect solution, btw can you explain by using theory that the remainder of a square number divided by 4 is always 0 or 1
Log in to reply
Every integer $n$ can be written as either $n = 2k, k \in \mathbb{Z}$ or $n = 2k+1, k \in \mathbb{Z}$ (even and odd numbers).
If we square both forms, we get
$( 2k )^2 = 4k^2 = 4a+0$ for some integer $a = k^2$
$( 2k+1 )^2 = 4k^2+4k+1 = 4 \left( k^2+k \right) +1 = 4b+1$ for some integer $b = k^2+k$
So the square of an even number is always divisible by $4$ and the square of an odd number is always one more than a multiple of $4$ .
You have a typo in the soln you have written 2 in place of 4
Log in to reply
Thanks for noting that, I think I have corrected the place you meant
Sorry, if this is obvious, but why did you divide by four? If every square number mod 4 is either 0 or 1, evenly dividing by 4 means that the number has a chance to be true square number. But you factored out a 4 and then divided by 4 again? I'm a little confused as to why you needed to do this...
Log in to reply
A square number can be written as, if even, (2c)^2 and odd as (2c+1)^2. Divinding by 4 we get: (2c)^2/4 = c^2 => zero remainder (2c+1)^2/4 = (4c^2+4c+1)/4 => we can see that in this case we obtain 1 as remainder.
But what about sqrt(1444...44)? [Ps. It's 1 following by 77 digits of 4]
** If my calc working properly, It's 2^(380058475033045993045349675188918159692)
Log in to reply
That's a nice nearmiss you've found there. According to Wolphram Alpha , it's only 0.00177 away from the next square number. But it's not a perfect square.
The numbers of this form (starting at 144) are all divisible by 4, but after dividing them by 4, the quotient mod 8 quickly stabilizes: it is 4, 1, 3, 7, 7, 7... as can easily be checked. Neither 3 nor 7 are quadratic residues mod 8, so the answer is No.
Consider the remainders of such numbers after dividing by 16. A quick check tells us that perfect squares are always congruent to $\color{#20A900} 0$ , $\color{#20A900} 1$ , $\color{#20A900} 4$ , or $\color{#20A900} 9$ modulo 16.
$\begin{aligned} 14 &\equiv \color{#D61F06}14 \ \ \color{#333333} \text{mod} \ 16 \\ 144 &\equiv \ \ \color{#20A900}0 \\ 1,444 &\equiv \ \ \color{#20A900}4 \\ 14,444 &\equiv \color{#D61F06}12 \\ 144,444 &\equiv \color{#D61F06}12 \\ 1,444,444 &\equiv \color{#D61F06}12 \end{aligned}$
Note that $10,000 = 16 \times 625$ , so every number from $14,444$ on is congruent to $4,444 \equiv \color{#D61F06}12$ mod 16, and thus not a perfect square.
[This train of thought was inspired by Henry U factoring out $2^2 = 4$ and then considering divisibility by 4.]
How does one check what perfect squares are congruent to modulo 16? Or any number, for that matter?
Log in to reply
Look up modular arithmetic . There are only 16 possible remainders when you divide by 16: 0, 1, 2, ..., 14, 15. Just look at the squares of those numbers (so the perfect squares from 0 to 225) and see what the remainders are when dividing by 16. It doesn't take too long, and you see a lot of repeated values.
$0^2 = \ \ 0 = 16 \times 0 + \color{#20A900} 0 \ \ \ \ \ \ \ \ \color{#333333} \ \ 8^2 = \ \ 64 = 16 \times \ 4 + \color{#20A900} 0$
$1^2 = \ \ 1 = 16 \times 0 + \color{#20A900} 1 \ \ \ \ \ \ \ \ \color{#333333} \ \ 9^2 = \ \ 81 = 16 \times \ 5 + \color{#20A900} 1$
$2^2 = \ \ 4 = 16 \times 0 + \color{#20A900} 4 \ \ \ \ \ \ \ \ \color{#333333} 10^2 = 100 = 16 \times \ 6 + \color{#20A900} 4$
$3^2 = \ \ 9 = 16 \times 0 + \color{#20A900} 9 \ \ \ \ \ \ \ \ \color{#333333} 11^2 = 121 = 16 \times \ 7 + \color{#20A900} 9$
$4^2 = 16 = 16 \times 1 + \color{#20A900} 0 \ \ \ \ \ \ \ \ \color{#333333} 12^2 = 144 = 16 \times \ 9 + \color{#20A900} 0$
$5^2 = 25 = 16 \times 1 + \color{#20A900} 9 \ \ \ \ \ \ \ \ \color{#333333} 13^2 = 169 = 16 \times 10 + \color{#20A900} 9$
$6^2 = 36 = 16 \times 2 + \color{#20A900} 4 \ \ \ \ \ \ \ \ \color{#333333} 14^2 = 196 = 16 \times 12 + \color{#20A900} 4$
$7^2 = 49 = 16 \times 3 + \color{#20A900} 1 \ \ \ \ \ \ \ \ \color{#333333} 15^2 = 225 = 16 \times 14 + \color{#20A900} 1$
Log in to reply
Oh interesting, I had the same question! But how does one think of “Hmm.. lemme check the residue mod 16? lol just asking
Since any number $1444\ldots 444$ is even, it must be the square of an even number, i.e. $1444\ldots 444 = (2k)^2 = 4k^2$ .
Thus any $1444\ldots 444$ is a multiple of $4$ .
In our case $144 = 12^2 = (2\cdot 6)^2 = 4\cdot 36$
and $1444 = 38^2 = (2\cdot 19)^2 = 4\cdot 361$ .
Now let's take a look at $1444\ldots 444$ numbers with more than two $4$ digits: by dividing any such number by $4$ we get $361\ldots 111$ , in fact
$\frac{{\color{#0000ff}{144}}4\ldots 444}{4} = \frac{{\color{#0000ff}{1440\ldots 000}}}{4} + \frac{4\ldots 444}{4} = {\color{#0000ff}{360\ldots 000}} + 1\ldots 111 = {\color{#0000ff}{36}} 1\ldots 111$ .
Any $361\ldots 111$ is an odd number, thus it must be the square of an odd number, i.e. $361\ldots 111 = (2l+1)^2 = 4l^2 + 4l +1$ .
By rearranging we see that $361\ldots 110 = 4l^2 + 4l = 4(l^2 + l)$
i.e. any number on the left must be a multiple of $4$ ; but any such number must be divisible by $4$ , thus it must have the last two digits divisible by $4$ , which in our case is never true for $10$ is not divisible by $4$ .
Summing up: we have just proven that any $361\ldots 111$ (with two or more $1$ digits) can't be the square of an integer number $k$ (see first line), so the answer is that there are no other $1444\ldots 444$ that are perfect squares.
Let 144...4 (with n fours) be a perfect square. Since its even, we may let 4k^2 = 144...4=10^n +44...4. This implies, k^2 = 25×10^(n2) + 11...1. Now, if n is greater than 3, then 25×10^(n2) is a multiple of 4 and the remaining 111....1=11...100+11, which is of the form 4a+3. So the whole RHS is of the form 4b+3, which can never be a perfect square.
If $x^2=14...4$ then $x^24=(x+2)(x2)$ is a multiple of 10, so x is even and $x=+/2(mod 5)$ : combined the last digit of x must be 2 or 8. Below, a, b and c are nonnegative integers.
1) Suppose $x=10a+2$ . Then $x^2 = 100a^2+40a+4$ $\implies$ a must end on 1 or 6 $\implies$ x must end on 12 or 62
1.1) Suppose $x =100b+12$ . Then $x^2 = 10000b^2+2400b+144$ , implying that the 3rd digit from the right in $x^2$ is odd. The only possibility satisfying the pattern is $x^2 = 144$ .
1.2) Suppose $x =100b+62$ . Then $x^2 =10000b^2+12400b+3844$ . Now 4b+8 must end on 4, so b must end on a 4 or a 9, so x must end on 462 or 962.
1.2.1) Suppose $x=1000c+462$ . Then $x^2=1000000c^2+2×1000×462×c+213444$
1.2.2) Suppose $x=1000c+962$ . Then $x^2=1000000c^2+2×1000×962×c+925444$
For both these cases there is no solution because the digit at position 4 from the right is odd (and it cannot be the leading 1 since $x^2 > 1444$ ).
Summarizing: The only solution for possibility 1) is $x=12$ .
2) Suppose x ends on an 8, so $x=10a+8$ . Then $x^2 = 100a^2+160a+64$ $\implies$ 6a+6 must end on a 4 $\implies$ 6a ends on an 8 $\implies$ a ends on a 3 or 8. $\implies$ x ends on 38 or 88
2.1) suppose that x ends on 38. $x^2=(100b+38)^2=10000b^2+7600b+1444$ . Possibilities are: $b=0$ or $b=5 (mod 10)$ $\implies$ x ends on 038 or 538
2.1.1) if x ends on 038, the 4th position from the right is odd so $b=0$ $\implies$ $x=38$ is the only solution.
2.1.2) if x ends on 538, $x^2=(1000c+538)^2=1000000c^2+1076c+289444$ . Here too, position 4 from the right is odd and $x^2 >1444$ .
2.2) suppose that x ends on 88. $x^2=(100b+88)^2=10000b^2+17600b+7744$ . Position 3 from the right is odd and $x^2 > 144$ .
Summarizing: The only solution for possibility 2) is x=38, and 12 and 38 are the only solutions for x.
I was lazy and wrote a computer program. I tested it to 100,000,000 numbers and decided that I was pretty sure the answer was no.
function checkNumber (n) {
var arg = n.toString();
var arr = arg.split("");
if (arr[0] === "1") {
var counter = 0;
for (var i = 1; i < arr.length; i++) {
if (arr[i] === "4") {
counter++;
}
}
if (counter === arr.length  1) {
return true
} else {
return false
}
} else {
return false;
}
}
var check = 0;
for (var i = 4; i <= 100000000; i++) {
if (checkNumber(i*i)) {
check++;
}
}
console.log(check)
python
for i in range(10000):
for j in range(200):
if i*i==int('1'+'4'*j):
print(i,flush=1)
I used brute force.
I don't know much about python and runtime, but I think you could also have used
1 

That way, you generate the number, take its square root and check if it is an integer.
Problem Loading...
Note Loading...
Set Loading...
Every number $1 \underbrace{44 \ldots 44}_{\text{n digits}}$ can be written as $10^n + \underbrace{44 \ldots 44}_{\text{n digits}} = 10^n + 4 \cdot ( \underbrace{11 \ldots 11}_{\text{n digits}} ) = 10^n + 4 \cdot \frac {\left( 10^n1 \right)} 9$ .
For $n \geq 2$ , we can factor out $2^2$ , since we only want to prove that the expression is not a perfect square.
$10^n + 4 \cdot \frac {\left( 10^n1 \right)} 9 = 4 \cdot \left( 25 \cdot 10^{n2} + \frac {\left( 10^n1 \right)} 9 \right)$
Let's look at the remainder when dividing by $4$ . The remainder of a square number divided by $4$ is always $0$ or $1$ .
The remainder of a sum is the sum of the remainders, so the remainder of $25 \cdot 10^{n2} + \frac {\left( 10^n1 \right)} 9$ is the remainder of $25 \cdot 10^{n2}$ , which is $0$ for $n \geq 4$ , plus the remainder of $\frac {\left( 10^n1 \right)} 9 = \underbrace{11 \ldots 11}_{\text{n digits}}$
To test for divisibility by $4$ , we look at the two last digits, $11$ . They give a remainder of $3$ when divided by $4$ . But since the remainder of a perfect square is either $0$ or $1$ , this number with remainder $3$ cannot be a perfect square, so there are No other such numbers.