Login|Contact Us
Question and Answer

Programming

Ask a Programming Question, Get an Answer ASAP!

  • Ask A Question
  • Browse Answers
  • Meet The Experts
  • How JustAnswer Works

Generate a set of test inputs and expected results for the

 
lifesaver's Avatar
  • Answered by:lifesaver
  • Computer Software Engineer
  • Positive Feedback: 100.0 %
  • Accepted Answers: 944
Verified Expert
in Programming

Recent Feedback

Positive
great help...thanx
Positive
lifesaver was very helpful and patient. The installation was a nightmare. I'm a...
Positive
Thanks so much!
Positive
When he gives you advice, if it does not resolve the problem -- be sure to tell...
Positive
ok
Positive
ok
Positive
good
Positive
ok
Positive
i can see
Positive
very good

Customer Question

Generate a set of test inputs and expected results for the Currency Conversion program.

Submitted: 1424 days and 14 hours ago.
Category: Programming
Value: $15
Status: CLOSED
Picture
Expert:  lifesaver replied1424 days and 14 hours ago.

Hi,
Please upload your program.

Without your program it will be impossible to generate the tests inputs and outputs.

Customer replied1424 days and 14 hours ago.

Main Module

 

Declare selection as integer

Declare currencyType as Integer

Declare internationalValue as real

Declare USValue as real

 

Do While user wants to continue

Display Menu

Get International Value

Convert Currency

Display Results

End loop

Print exit message

End Main Module

 

Display Menu

 

Declare continue as Boolean

Set continue = true

While continue = true

Display "Welcome to the international currency conversion program"

Display "Please make a selection"

Display "International Currency Types:"

Display "1: Canadian Dollars"

Display "2: Mexican Pesos"

Display "3: English Pounds"

Display "4: Japanese Yen"

Display "5: French Francs"

Display "6: Quit"

Display "Enter a selection:";

 

Input currencyType

 

If currencyType >= 1 AND currencyType <= 5 then

Set continue = false

else if currencyType = 6

Display "Quitting Currency Conversion"

continue = false

else

Display ""Error 4: Invalid menu selection."

continue = true

end if

 

end While

 

End Display Menu

 

Get International Value

 

Declare value as integer

Declare continue as Boolean

Set continue = true

While continue = true

Display "Enter a currency value (positive number): "

Input internationalValue

if internationalValue > 0 AND internationValue <=(NNN) NNN-NNNNthen

continue = false

else

Display ""Error 1: Invalid input--Negative Number"

continue = true

end if

end while

 

End Get International Value

 

Convert Currency

 

Declare rate as real

Select Case of currencyType

case 1:

Set rate = 1.4680

case 2:

Set rate = 9.5085

case 3:

Set rate = .6085

case 4:

Set rate = 104,9;

case 5:

Set rate = 6.2561

default:

Set rate = 0.0

End Case

USValue = rate * internationalValue

 

End Convert Currency

 

Display Results

 

Declare nation as string

Declare currency as string

Select Case of currencyType

case CANADIAN:

nation = "Canadian";

currency = "Dollars";

case MEXICAN:

nation = "Mexican";

currency = "Pesos";

case ENGLISH:

nation = "English";

currency = "Pounds";

case JAPANESE:

nation = "Japanese";

currency = "Yen";

case FRENCH:

nation = "French";

currency = "Francs";

default:

nation = "No country";

currency = "";

End Case

if currency <> "" then

Display "The value of ", internationalValue, " " , nation, " ", currency, " is ",

usValue, " dollars"

else

Display "Error 5: Invalid currency type."

end if

 

End Display Results

Picture
Expert:  lifesaver replied1424 days and 13 hours ago.

Ok.

I will post my answer within a couple of hours.

Customer replied1424 days and 13 hours ago.

I really appreciate your help! I have been sick and I am so lost in this class! Please let me know if there is anything else you need from me! I am not even sure if that code is correct.

Picture
Expert:  lifesaver replied1424 days and 13 hours ago.

Ok.

I will take care of the code too.

An initial glance indicates a lot of errors,

Customer replied1424 days and 13 hours ago.

I am suppose to have 3 "display menu" test cases, 4 Get_Int_Value Test, 6 Convert Currency Test, 6 Display Results Test Cases, and 3 Currency Conversion Integration Test. These can be presented in a table. Hope this helps!

Picture
Expert:  lifesaver replied1424 days and 13 hours ago.

Ok.

I would like you to upload your original question.(not the program)

Also i hope you don't mind adding some bonus for the efforts involved.

Customer replied1424 days and 12 hours ago.

Assignment: Currency Conversion Test Procedure

Objective of Assignment: Generate a set of test inputs and expected results for the Currency Conversion program.

Display Menu Test Cases
12 Points Possible

Points Possible

Points Earned

Comments

Test Case 1:

4

 

Test Case 2:

4

 

Test Case 3:

4

 

Get_Int_Value Test
16 Points Possible

Points Possible

Points Earned

Comments

Test Case 1:

4

 

Test Case 2:

4

 

Test Case 3:

4

 

Test Case 4:

4

 

Convert Currency Test
24 Points Possible

Points Possible

Points Earned

Comments

Test Case 1:

4

 

Test Case 2:

4

 

Test Case 3:

4

 

Test Case 4:

4

 

Test Case 5:

4

 

Test Case 6:

4

 

Display Results Test Cases
24 Points Possible

Points Possible

Points Earned

Comments

Test Case 1:

4

 

Test Case 2:

4

 

Test Case 3:

4

 

Test Case 4:

4

 

Test Case 5:

4

 

Test Case 6:

4

 

Currency Conversion Integration Test
14 Points Possible

Points Possible

Points Earned

Comments

Test Case 1:

5

 

Test Case 2:

5

 

Test Case 3:

4

 

 

OF COURSE!!! Bonus for SURE!!!

Picture
Expert:  lifesaver replied1424 days and 12 hours ago.

This is your present assignment.Right?

I will do it ina tabular format.

But i need the question for which you have wrote the Currency Conversion program/pseudocode.

Customer replied1424 days and 11 hours ago.

I am not sure that I understand what you are looking for. Here is the original assignment for the currency conversion:

 

 

  • Complete requirements analysis
  • Design
  • Verification
  • Validation and test documentation

 

The Currency Conversion application is a menu-driven program that allows users to select one of five international currency types, input the amount of a foreign currency, and then convert the foreign currency to dollars. The program displays the equivalent dollar amount and returns the user to the menu until he or she enters another conversion or quits the program.

International currency type (menu selection)

  • Canadian dollars (rate: 1 U.S. dollar = 1.4680 Canadian dollars)
  • Mexican pesos (rate: 1 U.S. dollar = 9.5085 pesos)
  • English pounds (rate: 1.6433 U.S. dollars = 1 pound)
  • Japanese yen (rate: 1 U.S. dollar =(NNN) NNN-NNNNyen)
  • French francs (rate: 1 U.S. dollar = 6.2561 francs)

 

That is what all of this is suppose to lead to! However, I am affraid that one too many pills has made me completely lose my mind!!

Picture
Expert:  lifesaver replied1424 days and 11 hours ago.

Yes this exactly what i wanted the problem statement.

Hope you have got some time for this assignment.

Customer replied1424 days and 11 hours ago.

I make time!!! Don't worry!! BIG bonus for your help!!!

Customer replied1424 days and 2 hours ago.

Hi Livesaver! How is it coming?

Picture
Expert:  lifesaver replied1424 days and 2 hours ago.

Hi there,

Everything is fine.I will post the code and test table within the next 2 to 3 hours.

Customer replied1424 days and 1 hours ago.

AWESOME! Will everybody be able to see this answer?

Picture
Expert:  lifesaver replied1424 days and 1 hours ago.

yes but you i will delete the answers after you receive them or you can also close this question after receiving the answer,.

Picture
Expert:  lifesaver replied1423 days and 19 hours ago.

Your pseudcode and test cases are complete.I have uplaoded both the word documents to a single zipped folder.

CLICK HERE! to downlaod the answers.

Hope this helps.

Best regards,
lifesaver

Customer replied1423 days and 16 hours ago.

Good Morning,

 

THANK YOU!! THANK YOU!!!! THANK YOU!!! A couple of questions, if I close this, am I able to reopen this again to get the files? Also, is this the final pseudocode? Lastly, there is part of the test cases missing:

 

Display Results Test Cases
24 Points Possible

Points Possible

Points Earned

Comments

Test Case 1:

4

 

Test Case 2:

4

 

Test Case 3:

4

 

Test Case 4:

4

 

Test Case 5:

4

 

Test Case 6:

4

 

Picture
Expert:  lifesaver replied1423 days and 15 hours ago.

Good Morning.

I would like you to wait for about 20 minutes before closing the question as i am not sure if you can reopen it.

I will answer the remain test cases within few minutes.

Also the pseudocode provided is complete and final.

Customer replied1423 days and 15 hours ago.

OMG!!! You are my new hero!!!

Accepted Answer

Picture
Expert:  lifesaver replied1423 days and 15 hours ago.

There wasn't a major mistake in the test cases.

A minor one. i combined the results of test cases of Convert_Currency Module Display Results module together.

Convert_Currency Module function is to simply convert the values

Display Results module function is to simply display the results.

I converted and then showed the value together in one step instead of two.

Anyway HERE!!! goes your final answer.

You can now close the question after you accept my answer.

Thanks.
Hope this helps.

lifesaver40021.5313226042

Expert TypeComputer Software Engineer
Category: Programming
Pos. Feedback: 100.0 %
Accepts: 944
Answered: 7/27/2009

Experience: Several years of intensive programming and application development experience in various platforms.

Ask this Expert a Question >
Customer replied1422 days and 4 hours ago.

Greetings,

 

Thank you so much! I just wanted to know if you got the bonus? Also, how do I close this question?

 

Thanks again!

Picture
Expert:  lifesaver replied1421 days and 12 hours ago.

Yes,I got the money and the bonus.Thanks.

Don't worry.I will close the question.

Customer replied1410 days and 8 hours ago.

Do you still have the code that you did for this question? I have a second part to it that I need some help with. I will open another question, but I just want to know if you still have the coding that you did.

Picture
Expert:  lifesaver replied1410 days and 8 hours ago.

Yes i do...

Customer replied1410 days and 8 hours ago.

GREAT!! Do I need to open a new question for this, or post it here? It is due on Wednesday.

Picture
Expert:  lifesaver replied1410 days and 8 hours ago.

If its related to this question you can post it here itself.

Customer replied1410 days and 8 hours ago.

It is related. I need the below information for the code that you created:

 

Application-Level Requirements
At least 5 key requirements identified and described

Input Process Output Table
4 inputs identified
4 processes identified
3 outputs identified

Design
Hierarchy chart w/5 modules
Flowchart for each module
Pseudocode for each module (this is what you already did)
Test cases for the program (this is what you already did)

Picture
Expert:  lifesaver replied1410 days and 8 hours ago.

Ok i will take a look at this latter.

My first target is to finish you other assignment within the next two hours atleast.

Customer replied1407 days and 4 hours ago.

Hi! I hope all is well! Is this something you are still working on for me?

Picture
Expert:  lifesaver replied1407 days and 3 hours ago.

Yes.Sure/

I was ill and i couldn't finish your work.

THough i am still recovering,Please give me two hours.I will do my job.

Customer replied1407 days and 3 hours ago.

NO!! Please rest! Your health is much more important!!

Picture
Expert:  lifesaver replied1407 days and 3 hours ago.

Thank you but job is job.

ANyway,i went to my friend whi is a doc and his medicine has worked.

I can atleast work now.

Full recovery will still require some time but i am in a posiition to complete your work now..

I ahve already completed the application level requirements

Customer replied1407 days and 2 hours ago.

Well how about a compromise? Let's plan on having it ready on Friday? Is that fair? I need you well! This is only my first computer class! Wink

Picture
Expert:  lifesaver replied1407 days and 2 hours ago.

Thanks.

I will go back to rest.

I will complete the work befored thursday night..

Customer replied1405 days and 16 hours ago.

Good Morning! How are you feeling? I spoke to customer service and I will be able to make sure you are paid for your help with this. Thanks again!

Picture
Expert:  lifesaver replied1405 days and 16 hours ago.

Feeling great now.

DIdnot expect that i would recover so soon.

Your work is almost complete.

Application-Level Requirements(complete)
At least 5 key requirements identified and described

Input Process Output Table(complete)
4 inputs identified
4 processes identified
3 outputs identified

Design
Hierarchy chart w/5 modules(complete)
Flowchart for each module(2 modules remaining)

I would have completed it now but i have to go out now.

I need 2 to 3 hours more to complete the remaining flowcharts.Hope its Ok with you?lifesaver40039.4836412037

Customer replied1405 days and 16 hours ago.

That is great! I will be back online this evening! Hope that works for you! I am glad you are feeling better!

Picture
Expert:  lifesaver replied1405 days and 16 hours ago.

Syre.

Your answer will be ready in 2 to 3 hours from now..

Accepted Answer

Picture
Expert:  lifesaver replied1405 days and 12 hours ago.

Eveything is complete now.

I ahve uploaded all the parts to a single zipped folder.

CLICK HERE! to download

Let me know if you face any problems downloading the files.

Expert TypeComputer Software Engineer
Category: Programming
Pos. Feedback: 100.0 %
Accepts: 944
Answered: 8/14/2009

Experience: Several years of intensive programming and application development experience in various platforms.

Ask this Expert a Question >
Customer replied1405 days and 5 hours ago.

Hi! Thank you for everything! I am waiting on a refund from this site to go through. Once it is done, I want to add a bonus for you. Thank you for all of your hard work!

Picture
Expert:  lifesaver replied1405 days ago.

Thanks.

Take your own time and authorize the payment at your will.

 
Tweet

4 Programmers are Online Right Now

Ask Your Question Now
Programming Questions Date Submitted
Submit pseudocode and a flowchart for the following programming 6/10/2013
I would like to give a directory and then report on the extensions 6/9/2013
Can you help me with a programming assignment? 6/9/2013
I'm looking for someone to tutor me, for programming, and softwar 6/3/2013
hi there'i have four questions about java its all about 5/29/2013
For The Doctor ONLY - Please fix the Doe Valley town Meeting 5/18/2013
Scenario: 5/17/2013
I need help with my website, I put in the Infolink ad code 5/17/2013
I need to make the submit button bigger 5/15/2013
Need a java programming to fulfill the following requirements: 1. 5/13/2013
RSS
Next 10 >
Ask A Programmer
Type Your Programming Question Here...
characters left:

Top Programming Experts

See More Programmers

In The News

Nbc
Washington Post
New York Times
Cnn
Learn More

How It Works

  • Ask an Expert
  • Get a Professional Answer
  • Ask Followup Questions
  • 100% Satisfaction Guarantee
Learn More

Ask a Programmer

Get a Professional Answer. 100% Satisfaction Guaranteed.
123 Programmers are Online Now
Type Your Programming Question Here...
characters left:
Disclaimer: Information in questions, answers, and other posts on this site ("Posts") comes from individual users, not JustAnswer; JustAnswer is not responsible for Posts. Posts are for general information, are not intended to substitute for informed professional advice (medical, legal, veterinary, financial, etc.), or to establish a professional-client relationship. The site and services are provided "as is" with no warranty or representations by JustAnswer regarding the qualifications of Experts. To see what credentials have been verified by a third-party service, please click on the "Verified" symbol in some Experts' profiles. JustAnswer is not intended or designed for EMERGENCY questions which should be directed immediately by telephone or in-person to qualified professionals.
Truste
Contact Us | Terms of Service | Privacy & Security | About Us | Our Network
© 2003-2013 JustAnswer LLC
  • Pearl.com
  • JustAnswer UK
  • JustAnswer Germany
  • JustAnswer Spanish
  • JustAnswer Japan