Changing the signs

Logic Level 1

0 = 1 2 3 4 5 6 7 8 9 \Large 0 = 1\ \square\ 2\ \square\ 3\ \square\ 4\ \square\ 5\ \square\ 6\ \square\ 7\ \square\ 8\ \square\ 9

Can you fill the boxes with + + and - to make this equation true?

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 non-javascript version of this page . We're sorry about the hassle.

21 solutions

Marta Reece
Jul 30, 2017

If we use only + + signs, we get the sum of all of the numbers, that is 9 × 10 2 = 45 \frac{9\times10}2=45

(Using the fact that the sum of all numbers from 1 to n n is given by n ( n + 1 ) 2 \frac{n(n+1)}2 ).

If we switch one of the + + signs for a - sign, we subtract 2 2 times the number which had its sign switched.

We are therefore only able to subtract even numbers.

The number 45 45 is odd.

Subtracting even numbers will never get us to zero.

Let's assume there is a solution, with A the sum of the numbers to be added and B the sum of the ones to be subtracted. So A-B=0 But if A-B=0 then A=B and A+B=2A, so A+B is even. And it's true the opposite: If A+B is not even then A-B is not null

carlo toniolo - 3 years, 7 months ago

Challenge Master Note: 0 = 1 + 2 + + n 0=1+2+\cdots + n The equation above is clearly wrong for n n . Find the value(s) of n n such that I can replace one or more addition sign ( + + ) with the subtraction sign ( - ) such that the aforementioned equation can be true.

Pi Han Goh - 3 years, 10 months ago

Log in to reply

The equation is wrong for n = 9 n=9 no matter how many addition signs are replaced with subtraction signs. It could be made correct for those n n s for which n ( n + 1 ) 2 \frac{n(n+1)}2 is even. Those are n n s which can be written in one of two following forms, either as 4 a 4a or 4 a 1 4a-1 , where a a is a positive integer. That would be 3 , 4 , 7 , 8 , 11 , 12 , . . . . 3, 4, 7, 8, 11, 12, ....

For example 0 = 1 + 2 + 3 + 4 0=1+2+3+4 , which is not true, can be changed to 0 = 1 2 3 + 4 0=1-2-3+4 , which is.

Marta Reece - 3 years, 10 months ago

Log in to reply

Hey @Pi Han Goh .. I'm not getting the logic.. Can you elaborate pls

Vivek Muthuvel - 3 years, 10 months ago

After carefully checking all of the 512 512 possibilities, we see that the equation is clearly always false.

https://pastebin.com/ZVrsQhSE

Jesse Nieminen - 3 years, 10 months ago

Log in to reply

I can't understand your comment, I think it's a LaTex error.

Munem Shahriar - 3 years, 10 months ago

Log in to reply

@Munem Shahriar My comment contains a list of all possible ways one can choose the signs and none of them yield zero. Hence the answer is No.

Jesse Nieminen - 3 years, 10 months ago

Log in to reply

@Jesse Nieminen Legible presentation is important.

Richard Desper - 3 years, 10 months ago

Log in to reply

@Richard Desper How is it not legible?

Jesse Nieminen - 3 years, 10 months ago

Log in to reply

@Jesse Nieminen I was getting a few hundred lines of LaTeX code. It is now being translated properly. So it's now legible, just annoying.

Richard Desper - 3 years, 10 months ago

Log in to reply

@Richard Desper I'll put it to pastebin.com and add a link.

Jesse Nieminen - 3 years, 10 months ago

To summarize, the key observation here is to notice how the parity changes. This is very helpful indeed. Neat solution!

Agnishom Chattopadhyay - 3 years, 10 months ago

Where can I learn more about this ((9*10)/2) rule? Seems eminently efficient but I've no idea from where it derives. TYVM.

e m - 3 years, 10 months ago

Log in to reply

https://brilliant.org/wiki/sum-of-n-n2-or-n3/

Jesse Nieminen - 3 years, 10 months ago

This is the sum of all numbers from 1 to n n being given by n ( n + 1 ) 2 \frac{n(n+1)}2 .

Marta Reece - 3 years, 10 months ago

( a / 4 , a / 4 , a / 4 ) (a/4 \ , a/4 \ , a/4 )

ANUBHAV BHATIA - 3 years, 10 months ago

Log in to reply

Could you please elaborate. I am not understanding what your comment is trying to say.

Marta Reece - 3 years, 10 months ago

1+2-3+4+5-6+7-8-9=0

Peter Cameron - 3 years, 10 months ago

Log in to reply

Actually it is 7 -7 .

Jesse Nieminen - 3 years, 10 months ago

This is the neatest solution. I would explain it with weighing scale. We have 9 steel weights so we cannot cut them in half. We need to balance the scale using all the weights. This is only possible if the total weight can be divided into two equal halves without cutting any. Which is the same as the sum 1...9 being a whole number.

Spicy Brigadoon - 3 years, 10 months ago

Log in to reply

Nice idea. But a whole number would work, actually, if it were even.

Marta Reece - 3 years, 10 months ago

Log in to reply

Ugh, I meant to say same as sum 1..9 being an even number, of course.

Spicy Brigadoon - 3 years, 9 months ago

0 = 12 3 4 5 6 + 7 + 8 9 0=12-3-4-5-6+7+8-9\quad :)

Abraham Zhang - 2 years, 7 months ago
Richard Desper
Aug 6, 2017

Let's treat subtraction as addition of the negative of a number. The right hand side is the sum of four even and five odd numbers. Thus it will be odd. QED

That's how I solved it. Very elegant! :)

Snehal Shekatkar - 3 years, 10 months ago

7 minus 6 is 1. 1 Minus 5 is (-4). (-4) Plus 4 is 0. 0 Plus 3 is 3. 3 minus 2 is 1. 1 Minus 1 is 0.

Noel Deal - 3 years, 10 months ago

Log in to reply

Can you explain what your point here is?

Agnishom Chattopadhyay - 3 years, 10 months ago

You have added 4 odds and 3 evens to get zero. The parity of a sum of integers will be determined by the number of odds in the sum. If you have an odd number of odds in the sum, the sum will be odd. If you have an even number of odds in the sum, the sum will be even. The fact follows from the basic observations: Odd + Odd = Even, Odd + Even = Odd, and Even + Even = Even.

Richard Desper - 3 years, 10 months ago

Yes, this indeed works. A similar method would be Oliver's idea.

Agnishom Chattopadhyay - 3 years, 10 months ago

Noel is correct on parity. If you take any sequence of sums of two numbers (negative or positive) and arrive at zero at any point before the end, you can show that the remaining numbers of the sequence cannot get to zero a second time.

Erik Brown - 3 years, 10 months ago

A great solution

A Former Brilliant Member - 3 years, 8 months ago
Oliver Papillo
Jul 29, 2017

For this to be possible, we need to be able to form 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 2 \frac{1+2+3+4+5+6+7+8+9}{2} by addition of integers 9 9 and below.

1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 = 45 1+2+3+4+5+6+7+8+9 = 45

45 2 = 22.5 \frac{45}{2} = 22.5 which is not an integer, and so cannot be formed by addition of integers.

Moderator note:

Just to clarify, solving the given problem is similar to dividing the numbers 1 through 9 into two sets where they equal each other. To show an example with 1, 2, 3, and 6: 1 + 2 + 3 6 = 0 1 + 2 + 3 - 6 = 0 so 1 + 2 + 3 = 6 ; 1 + 2 + 3 = 6 ; the two sets are {1, 2, 3} and {6}.

(The 1 doesn't let you change it to be negative, but since all the other numbers can be moved to either side of the equal sign this fact doesn't matter.)

In any case, if the subdivision can happen, the equation can be written as shown above into a = a a = a where a a is an integer that is necessarily half of the sum of all the integers in the set. This is why 45 / 2 45/2 being 22.5 22.5 makes the circumstance impossible.

why you divided 45 by 2?

Aditya Prasad - 3 years, 10 months ago

This is a clean trick. I believe what you are trying to do here is to partition the digits into those which have a + + sign and those which have a - sign. Because both sides must add up to an equal value, this cannot be done.

Agnishom Chattopadhyay - 3 years, 10 months ago

Consider the odd numbers 1,3,5,7,9 separately from the even number 2,4,6,8.

The sum or difference of two even numbers is even. Therefore, however you arrange the signs of 2, 4, 6 and 8, the result is always even.

The sum or difference of two odd numbers is even. But however, you choose odd numbers in pairs from the set 1, 3, 5, 7, 9 there will be an extra odd number which is unpaired. Therefore, however you arrange the signs of all five numbers, 1,3,5,7,9, the result is always odd.

Therefore, however you arrange the signs of 1,2,3,4,5,6,7,8,9 the result is odd.

But 0 is an even number. Therefore, it cannot be done.

Christopher Curzon - 3 years, 10 months ago

Easy...(1+9)-(2+8)+(3+7)-(4+6)+5 or -5 will never =0 Math counts coach from Florida

Maria Gerrity-bellizzi - 3 years, 10 months ago

Log in to reply

Yeah... This sounds the simplest way.

shalini chaurasia - 3 years, 10 months ago

I feel this lacks some details. You've stated a tautology but haven't explained why it's true. You haven't mentioned subtraction at all.

Richard Desper - 3 years, 10 months ago

Log in to reply

hey richard. he doesn't get to speaking about subtraction (or addition really) because he doesn't have to. you figure out the equation is a bust before it even gets that far. i'm good at math but no mathematician so i thought of it like this: if both sides are equal, what would they equal? well the right side adds up to the 45 so then each side of the equation would have to be 22.5, half of the sum of the numbers on right. well 22.5 isn't an integer so you know right there that it's not gonna work out. hope this helps.

Neville Braithwaite - 3 years, 10 months ago

Log in to reply

Thank you Neville! Have been searching all over places to understand this and you nailed it. I finally understood!

Xuyến Nguyễn - 3 years, 10 months ago

Log in to reply

@Xuyến Nguyễn Question reads ‘using plus and minus signs, not specifying plus to mean addition or positive or minus to mean subtraction or negative. 0= 1++2(3) 3-3(0)

Marc Deitch - 3 years, 10 months ago

I'm not yet good at writing proofs, but I devised the answer intuitively the same way. I considered the '-' sign to mean addition of a negative integer, thus we would need a an even sum if all signs were positive to be able to balance addition of positive and negative numbers.

Hans G - 3 years, 10 months ago

Simple and to the point explanation.

Jan Haarlow - 3 years, 10 months ago

What is 1+2-3+4-5-6+7 if it is not 0?

Eric Stallsmith - 3 years, 9 months ago

Didn't see the 8 or 9.

Eric Stallsmith - 3 years, 9 months ago
Jesse Nieminen
Aug 7, 2017

(In this context every ± \pm is independently - or + + )

1 ± 2 ± 3 ± 4 ± 5 ± 6 ± 7 ± 8 ± 9 1 ± 0 ± 1 ± 0 ± 1 ± 0 ± 1 ± 0 ± 1 1 ± 1 ± 1 ± 1 ± 1 1 + 1 + 1 + 1 + 1 5 1 ≢ 0 ( m o d 2 ) \begin{aligned} &1 \pm 2 \pm 3 \pm 4 \pm 5 \pm 6 \pm 7 \pm 8 \pm 9 \\ \equiv &1 \pm 0 \pm 1 \pm 0 \pm 1 \pm 0 \pm 1 \pm 0 \pm 1 \\ \equiv &1 \pm 1 \pm 1 \pm 1 \pm 1 \\ \equiv &1 + 1 + 1 + 1 + 1 \\ \equiv &5 \\ \equiv &1 \\ \not\equiv &0 \pmod{2}\end{aligned}

Meaning that one side of the equation is 0 ( m o d 2 ) 0 \pmod{2} and the other is 1 ( m o d 2 ) 1 \pmod{2} , which means that the equation is false.

Hence, the answer is No \boxed{\text{No}} .

This is indeed an interesting way to solve this problem. This is basically the same as Richard's solution, in a more formal setting.

Agnishom Chattopadhyay - 3 years, 10 months ago

Why in the fourth line did you change every ± \pm in + + sign?

Mattia Mariantoni - 3 years, 10 months ago
Mohammad Khaza
Aug 8, 2017

as we have to use only + , +,-

so, now, 1 + 2 + 3 + . . . . . . . . . . . + 9 = 45 1+2+3+...........+9=45 and 45 2 = 22.5 \frac{45}{2}=22.5 or not integer.

so, the least possible value of these numbers by using this two signs is= 23 22 = 1 23-22=1 .................[ 23 + 22 = 45 23+22=45 ]

so, it is not possible to make 0.

Oliver Clarke
Sep 10, 2017

Suppose there is a solution. Take both sides modulo 2, we get 0 1 ( m o d 2 ) 0 \equiv 1 \pmod 2 . Contradiction.

odd + even = odd odd + odd = even

here's as sort of "pseudo-algebraic" solution: there are 1 more odd numbers than even numbers, so 5odd + 4even = 2even + odd + 1even = 3even + 1odd = odd.

Yuppers, it works! =D

Pi Han Goh - 3 years, 10 months ago

Separate the numbers into groups of odd and even numbers. (1,3,5,7,9) and (2,4,6,8). Look at the even numbers first. No matter how you combine them with + or-, they will ALWAYS sum to an even number.
But there are 5 odd numbers. Hence no matter how you combine them with + or - , they will always give you an ODD number. Odd+Even can never result in zero since zero is effectively an even number. Even more basic, Odd+Even means they are DIFFERENT numbers so by definition can never sum to zero!

A more interesting question is what sequences CAN be summed to zero? Here is my hypothesis. Consider a sequence 1 2 3 4 .....n.

  1. If n is an even number and n/2 is an even number, then it WILL be possible to sum the sequence to zero.
  2. If n is an even number and n/2 is an odd number, then it will NOT be possible to sum the sequence to zero.
  3. If n is an odd number, and (n-1)/2 is an even number then it will NOT be possible to sum the sequence to zero.
  4. If n is an odd number, and (n-1)/2 is an odd number then it WILL be possible to sum the sequence to zero.

Example.

1 2 3....9 meets condition 3 above and will not sum to zero.

1 2 3....11 meets condition 4 and can sum to zero.

Answer (1+10)+(-2-9)+(3+8)+(-4-7)+(5+6)+(-11)=0

It all comes down to pairing sets of numbers with opposite signs!

David Punshon-Smith - 3 years, 10 months ago
Ji Vid
Aug 9, 2017

If you want it to be zero, all the numbers you add will have to have a sum of the next number that you'll use to subtract. The only one there is 1+2-3. After that the numbers get too high.

Auro Light
Aug 9, 2017

Let the sum of all (+) be A and the sum of all (-) be B.
A - B = 0, and A + B = 9×10/2 = 45,
=> A = B = 22.5.
Since A and B can not be natural numbers, the answer is no.


Saul Rosenthal
Aug 9, 2017

It's simple. Zero is an even number. There are 5 odd numbers in the sequence, so you have to end up with an odd number. QED

Elya Tagar
Aug 8, 2017

They add up to 45, so there's no way to divide that equally so one half cancels the other

Mo H
Aug 7, 2017

Proof by contradiction. Suppose there is a way. Since the sum is equal to 0 this implies all numbers taken away is equal to all the numbers added. Hence, twice the numbers taken away is the addition of all the numbers 1+2+3.....+9. So 1+2+3....+9=2y. However, 1+2+3.....+9=45. So this implies 45=2y where we know y must be an integer. This cannot be true since 45 is odd. Hence, there is no way this can be done.

Yay! Can you find also find all the possible values of n n such that the equation 0 = 1 0 2 0 0 n 0 = 1 \, \boxed{\phantom0} \, 2 \, \boxed{\phantom0} \, \cdots \, \boxed{\phantom0} \, n also has no solution (by filling in + and - only)?

Pi Han Goh - 3 years, 10 months ago
Tommy Chan
Aug 13, 2017

The sum of all the numbers is 45.

The magnitude of numbers signed to subtract must equal the magnitude of numbers assigned to pluses.

45 is odd, so it can't be evenly distributed between pluses and subtractions.

Therefore equation can't be made true.

... It helps sometimes to prove or disprove a theorem by assuming it is true then work backwards from there and see if it stays consistent. Happy solving!

Tommy your rational was same as mine the quotient of dividing 45 by 2 render a decimal. So it is an useless exercise try to combine + and - to get the balance.

Mariano PerezdelaCruz - 3 years, 5 months ago
Abhinav Jain
Aug 13, 2017

Since the sum of the digits is odd, I think it is not possible for them to satisfy the given criteria to be proved.

Yes, your instinct is right, but can you prove it?

Pi Han Goh - 3 years, 10 months ago
Lai Nung Siong
Aug 12, 2017

Answer is no

Why can't the answer be yes?

Pi Han Goh - 3 years, 10 months ago
Cesar Amable
Aug 8, 2017

I added the numbers and got 45, an odd number. Unable to divide by 2 and get an integer to somehow keep going and find the right combination. So I concluded that there is no solution.

Why is it important for the sum to be divisible by 2?

Pi Han Goh - 3 years, 10 months ago
Kevin Solo
Aug 8, 2017

1 + 9 = 10 2 + 8 = 10 3 + 7 = 10 4 + 6 = 10 remainder 5

Eliminate like pairs (10) and we are left with 5.

I don't understand/ What's so special about this number 5?

Pi Han Goh - 3 years, 10 months ago
Arianna Colella
Aug 8, 2017

For this equation to be true, we must find a way to make two equal sums with the set of digits given, so that one can be subtracted from the other. Each must be equal to half the sum of the entire set of digits. If the sum of all the digits is 45, both sets have to give 22.5. Since this is not a whole number, it is impossible to obtain it through the sum of any set of whole digits. The answer is no.

Since you know that the sum (45) is an odd number, can you determine all the possible values of n n (larger than 2) such that the equation below can be satisfied (by filling in + and - only)?

0 = 1 0 2 0 0 n 0 = 1 \, \boxed{\phantom0} \, 2 \, \boxed{\phantom0} \, \cdots \, \boxed{\phantom0} \, n

Pi Han Goh - 3 years, 10 months ago

If we place the positive and negative signs in such a way to make negative and positive tens.

We get 10 10 + 10 10 + 5 = 5 10 - 10 + 10 - 10 + 5 = 5

We could also end up with -5, but never with zero.

Hmmm, would your pattern works if we have more numbers given? That is, if we extend it to more than 8 boxes, can we still use your method to get the answer?

Pi Han Goh - 3 years, 10 months ago
Ilya Prokin
Aug 7, 2017

The sum is 45. Now split all numbers to 45 1s (1=1, 2=1+1, 3=1+1+1,...). Let's assign signs. To have a total of zero, the number of -1 should be balanced by +1. This is impossible because 45 is not divisible by 2.

This is indeed true. Oliver puts this in a clean way.

Agnishom Chattopadhyay - 3 years, 10 months ago

The sum of two of the numbers working from the outsides toward the centre all add up to 9. eg. 9+0=9; 8+1=9; 7+2=9; 6+3=9; 5+4=9. that equals 5x9=45 9-9+9-9+9=9.

Vaughan Ashley - 3 years, 10 months ago

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...