![]() |
|
|||||||
|
|
Thread Tools | Search this Thread | Rate Thread |
|
#1
|
|||
|
|||
Try to post the code of this program plzzz..Calculator is hard to solve!!!Write a program to model a simple calculator. Each data line should consist of the next operation to be performed from the list below and the right operand. Assume the left operand is the accumulator value(initial value of 0). You need a function scan_data with two output parameters that returns the operator and right opernad scanned from a data line. You need a function do_nest_op that performs the required operation.do_next_op has two input parameters (the operator and operand) and one input/output parameter (the accmulator). The valid operators are:
+ add - subtract * multiply / divide ^ power(raise left opernad to power of right operand) q quit Your calculator should display the accumulator value after each operation. A sample run follows. + 5.0 result so far is 5.0 ^ 2 result so far is 25.0 / 2.0 result so far is 12.5 q 0 final result is 12.5 |
|
#2
|
||||
|
||||
Re: Try to post the code of this program plzzz..Calculator is hard to solve!!!So you want us to write it for you, correct?
__________________
Got a cough? Go home tonight and eat a whole box of Ex-Lax. Tomorrow, you'll be afraid to cough. -- Pearl Williams |
|
#3
|
|||
|
|||
Re: Try to post the code of this program plzzz..Calculator is hard to solve!!!try if your code is also the same to my code also!!!!so post it plzzzzz
|
|
#4
|
||||
|
||||
Re: Try to post the code of this program plzzz..Calculator is hard to solve!!!Quote:
__________________
Got a cough? Go home tonight and eat a whole box of Ex-Lax. Tomorrow, you'll be afraid to cough. -- Pearl Williams |
Recent GIDBlog
Toyota - 2008 November Promotion by Nihal
| Thread Tools | Search this Thread |
| Rate This Thread | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Guidelines for posting requests for help - UPDATED! | WaltP | C Programming Language | 1 | 11-Nov-2007 22:05 |
| Can you help me solving this program!plzz post the code of this program plzz.. | albert_123 | C Programming Language | 2 | 12-Sep-2006 07:47 |
| How to sort random access file? | wmmccoy0910 | C Programming Language | 12 | 04-Sep-2006 04:40 |
| Compiling/Linking | roostercogburn | C Programming Language | 5 | 08-Nov-2005 15:32 |
| Guidelines for posting requests for help - UPDATED! | WaltP | C++ Forum | 0 | 21-Apr-2005 03:44 |
Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The