Hey guys,
I'm just starting out with C++. I've not done any object-orientated stuff so far, so I guess it's just like C. I would like to know if it is possible to put 3 conditions in an if statement? If not, how would you do it?
Situation:
I need something to be printed to screen when these conditions are true:
a + b > c
b + c > a
c + a > b
Can I put all that in one if statement or how would you suggest I do it?
Also, I'm having an issue with getting my last else statement to work right in a small program I wrote. I don't want to post the whole thing here. Is there anyone who I can contact about this via PM? I would really appreciate it and I'm sure if you are an intermediate c or c++ programmer you would be able to easily point out where I made a mistake.
Thank you
I'm just starting out with C++. I've not done any object-orientated stuff so far, so I guess it's just like C. I would like to know if it is possible to put 3 conditions in an if statement? If not, how would you do it?
Situation:
I need something to be printed to screen when these conditions are true:
a + b > c
b + c > a
c + a > b
Can I put all that in one if statement or how would you suggest I do it?
Also, I'm having an issue with getting my last else statement to work right in a small program I wrote. I don't want to post the whole thing here. Is there anyone who I can contact about this via PM? I would really appreciate it and I'm sure if you are an intermediate c or c++ programmer you would be able to easily point out where I made a mistake.
Thank you