![]() |
|
![]() | ||
|
Subject:
Microsoft c++ .net
Category: Computers Asked by: cringe-ga List Price: $5.00 |
Posted:
08 Sep 2002 18:30 PDT
Expires: 15 Sep 2002 14:20 PDT Question ID: 62918 |
write a visual c++ code that will allow the user to input the vales of lenght, width adn depth of a pool and display an answer. This must be in a very simple format that prints to the screen such as in a win32 cpp file that is run from the console | |
| |
| |
|
![]() | ||
|
There is no answer at this time. |
![]() | ||
|
Subject:
Re: Microsoft c++ .net
From: nathanysmith-ga on 10 Sep 2002 16:00 PDT |
well, if you want it to run straight from console: obviously, you need to switch data types if you want something other than ints [STAThread] public static void Main(string[] args) { int x,y,z; try { x=Convert.ToInt32(args[0]); y=Convert.ToInt32(args[1]); z=Convert.ToInt32(args[2]); Console.WriteLine("Volume Is: " + CalcVol(x,y,z).ToString()); } catch(Exception e) { Console.WriteLine("USAGE: VolCalc IntegerDimX IntegerDimY IntegerDimZ"); } } public static int CalcVol(int x,int y,int z) { return (x*y*z); } |
Subject:
Re: Microsoft c++ .net
From: nathanysmith-ga on 10 Sep 2002 16:01 PDT |
actually, it's c# but if they're running .NET , you may as well use it anyway |
If you feel that you have found inappropriate content, please let us know by emailing us at answers-support@google.com with the question ID listed above. Thank you. |
Search Google Answers for |
Google Home - Answers FAQ - Terms of Service - Privacy Policy |