S_inner=S_cyl+S_cap=2πR_cyl H_cyl+2πR_cap h_cap I've been entering this equation over and over in different ways but every time I press compile and enter the numbers it always shows up as a zero, can someone help me, please?

# how to write this equation in C++

Page 1 of 1## 3 Replies - 313 Views - Last Post: 06 February 2018 - 07:53 PM

##
**Replies To:** how to write this equation in C++

### #2

## Re: how to write this equation in C++

Posted 05 February 2018 - 08:44 PM

Based on what you have written - no!

Forget about programming whatever this equation is meant to do.

Can you solve this thing as an algebraic equation?

Also, if you want others to contribute then you will have to explain, in detail, what this equation is all about.

Based on what you have written I am not certain whether we are talking about physics or accountancy!

(Don't make the mistake of thinking that whatever ability we have in C++, automatically transfers to whatever domain of study this equation comes from.)

Forget about programming whatever this equation is meant to do.

Can you solve this thing as an algebraic equation?

Also, if you want others to contribute then you will have to explain, in detail, what this equation is all about.

Based on what you have written I am not certain whether we are talking about physics or accountancy!

(Don't make the mistake of thinking that whatever ability we have in C++, automatically transfers to whatever domain of study this equation comes from.)

### #3

## Re: how to write this equation in C++

Posted 05 February 2018 - 09:35 PM

You would have to post a small complete program which demonstrates your problem.

### #4

## Re: how to write this equation in C++

Posted 06 February 2018 - 07:53 PM

I agree with snoopy, stub out some code that incorporates your equation. this seems like a volume of a cylinder equation.

Page 1 of 1