How JustAnswer Works:
  • Ask an Expert
    Experts are full of valuable knowledge and are ready to help with any question. Credentials confirmed by a Fortune 500 verification firm.
  • Get a Professional Answer
    Via email, text message, or notification as you wait on our site.
    Ask follow up questions if you need to.
  • 100% Satisfaction Guarantee
    Rate the answer you receive.
Ask LogicPro Your Own Question
LogicPro
LogicPro, Computer Software Engineer
Category: Programming
Satisfied Customers: 12983
Experience:  Expert in C, C++, Java, DOT NET, Python, HTML, Javascript, Design.
29751445
Type Your Programming Question Here...
LogicPro is online now
A new question is answered every 9 seconds

1 create the loci for a program that calculates and displays

Resolved Question:

1 create the loci for a program that calculates and displays the amount of money you would have if you invested $ 1000 at 5% percent interest for one year. create a separate method to do the calculation and return the result to be displayed.

2. create an application class named numbers whose main () method holds two numeric variables. prompt the user for values for the variables. pass both variable to methods names sum() and difference (). create the logic for the methods sum () and difference (); they compute the sum of and difference between the values of two arguments, respectively each method should perform the appropriate computation and display the results

b. add a method named Product () to the numbers class. the product () method should compute the result when multiplying two numbers but not display the answer instead it should return the answer to the calling method which dispays the answer
Submitted: 7 years ago.
Category: Programming
Expert:  Kevin Bui replied 7 years ago.
Hi,



What language do you need this to be in?



Regards,

Kevin
Customer: replied 7 years ago.
i want it on

Pseudocode

Customer: replied 7 years ago.
are you still working on it
Customer: replied 7 years ago.

i'm reaply again just in case you didnt have the first replay .. i want it on Pseudocode
Expert:  Kevin Bui replied 7 years ago.
Hi,



Here it is:

[CODE] 1)

function calculateAmount()
amount := 1000 * 1.05
return amount
end function

procedure main()
display(calculateProfit())
end procedure

2)

class numbers

procedure main()
number1 := getInput()
number2 := getInput()

sum(number1, number2)
difference(number1, number)
display(product(number1, number2))
end procedure

procedure sum(a, b)
display(a + b)
end procedure

procedure difference(a, b)
display(a - b)
end procedure

function product(a, b)
return a * b
end function

end class
[/CODE]

Edited by Kevin Bui on 6/15/2010 at 4:34 AM EST
Kevin Bui, Computer Software Engineer
Category: Programming
Satisfied Customers: 108
Experience: 9+ years of experience and competitions in Assembly, C/C++, C#, and Java.
Kevin Bui and other Programming Specialists are ready to help you
Expert:  LogicPro replied 7 years ago.
Hi,
How are you doing?
I see previous answer is missing 2b part
Download this document containing all the parts of your question.
The code was written using previous style of code I gave.
Ask me if you need more information.

Edited by LogicPro on 6/15/2010 at 4:48 AM EST
LogicPro, Computer Software Engineer
Category: Programming
Satisfied Customers: 12983
Experience: Expert in C, C++, Java, DOT NET, Python, HTML, Javascript, Design.
LogicPro and other Programming Specialists are ready to help you
Expert:  Kevin Bui replied 7 years ago.
If you look carefully, my answer did indeed contain 2b part (the product method).

Edited by Kevin Bui on 6/15/2010 at 4:52 AM EST
Customer: replied 7 years ago.
thank you