Pia tunatoa huduma zifuatazo.

Tunatengeneza blogu, tovuti(website), youtube chaneli n.k.. Mawasiliano:
simu:+255763670000, Barua pepe: khalfanm021@gmail.com

Sunday, September 16, 2018

Question Aim: To calculate the volume of a sphere


Question: Write a block of code that prompts user to enter the radius, then compute and output the volume of a sphere. (Recall that volume V of a sphere of radius r is given by V = (4/3)PIr3 and assume PI = 3.14

Solution

if(r <= 0) This condition ensures that the radius cannot be zero or negative


PLEASE LEAVE A COMMENT, OR ANY OTHER QUESTIONS INVOLVING ANY OF THE FOLLOWING LANGUAGES, C++, PHP, JAVASCRRIPT, HTML, CSS, MYSQL

No comments:

Post a Comment