# Plus or Minus Notation?

Page 1 of 1

## 2 Replies - 20590 Views - Last Post: 15 January 2008 - 12:36 PMRate Topic: //<![CDATA[ rating = new ipb.rating( 'topic_rate_', { url: 'http://www.dreamincode.net/forums/index.php?app=forums&module=ajax&section=topics&do=rateTopic&t=40997&amp;s=1ea1d9af3be495e5877cae0645d3c8af&md5check=' + ipb.vars['secure_hash'], cur_rating: 0, rated: 0, allow_rate: 0, multi_rate: 1, show_rate_text: true } ); //]]>

### #1 captainhampton

• Jawsome++;

Reputation: 14
• Posts: 548
• Joined: 17-October 07

# Plus or Minus Notation?

Posted 15 January 2008 - 11:56 AM

I have a really quick question about if it is even possible to give a "plus or minus" notation within an equation, for example the quadratic formula discriminant:

(-b ± sqrt (b2 – 4 a c) / 2 a

I first thought perhaps:

```-b + || - .....

```

However that threw up errors,

I also tried

```-b +-.....

```

However it took the last "-" as a negative sign as opposed to plus or minus

any help would be appreciated

Is This A Good Question/Topic? 1

## Replies To: Plus or Minus Notation?

• g+ + -o drink whiskey.cpp

Reputation: 248
• Posts: 13,507
• Joined: 12-July 02

## Re: Plus or Minus Notation?

Posted 15 January 2008 - 12:17 PM

You have to remember that what you have there is actually two different formulas (although always presented as one). there is no native symbol in C or C++ to represent this. you could create a class to handle it if you wish.

### #3 captainhampton

• Jawsome++;

Reputation: 14
• Posts: 548
• Joined: 17-October 07

## Re: Plus or Minus Notation?

Posted 15 January 2008 - 12:36 PM

Amadeus, on 15 Jan, 2008 - 12:17 PM, said:

You have to remember that what you have there is actually two different formulas (although always presented as one). there is no native symbol in C or C++ to represent this. you could create a class to handle it if you wish.

Gotcha, thank you very much