View Single Post
  #1 (permalink)  
Old 10-05-2006, 12:06 AM
Sharp Sharp is offline
Newbie
 
Join Date: Oct 2006
Posts: 1
Credits: 0
Rep Power: 0
Sharp is on a distinguished road
Default Who can show me how to do this program?

I am so freaking lost. I am completely new to programming. I bought a java programming book to try and teach myself. This is one of the programs it asks you to make. It doesn't show you how to do it either. I have been able to do all the programs it has requested so far. I'm freakin stumped. It asks you to do this program without using the math operators. any help here would be greatly appreciated. Ill make it worth your time to respond. My e-mail is CastorTroy357@hotmail.com. thanks in advance to anyone that helps.

1)Prompt the user and accept a number from standard input.
2)Prompt the user and accept a symbol character from standard input. The symbol must be either an ^ or an !. If it is neither of these, display an error message and end the program.
3)If the symbol is a !, compute the factorial of the number entered in step 1 and display the result.
4) if the symbol is a ^, prompt the user to enter a second number, and then calculate the 1st number to the power of the 2nd number (similar to tonight's exercise). Display the result.
5) You must use iteration/loops for the factorial and exponent calculations
Reply With Quote

Sponsored Links