Ask Question, Ask an Expert

+61-413 786 465

info@mywordsolution.com

Ask Computer Engineering Expert

Part 1

Examine the pseudocode sample provided, and explain what it does line by line.

Description: This logic applies a discount on an item unless the discounted price is less than the whole sale price

Program: applyDiscount
Create variable productPrice as double
Create variable discount as double
Create variable wholesalePrice as double
Create variable discountedPrice as double
productPrice = get value from user input
discount = get value from user input
wholesalePrice = get value from user input
discountedPrice = productPrice * (1 - discount)
if (discountedPrice
discountedPrice = wholesalePrice
end if
Display discountedPrice
End program

Part 2

Present a solution using pseudocode similar to what you saw in part 1 to identify the logic needed to select a payment option and get payment details.

Declare all variables and their data types.

Display two options for the user to select from:

Electronic check with routing number and account number

Credit card with account number, expiration date and CVV code

Capture the payment option that the user selects.

Check the selected option using a decision-making statement and provide the corresponding statements to capture the payment information based on the selection.

Computer Engineering, Engineering

  • Category:- Computer Engineering
  • Reference No.:- M91797776

Have any Question?


Related Questions in Computer Engineering

A study indicates that the weights of adults are normally

A study indicates that the weights of adults are normally distributed with a mean of 140 lbs and a standard deviation of 25 lbs. Find a value of weight x such that only 20% of adults weigh less than that. A. 136 B.190 C. ...

Question suppose we have the following context-free grammar

Question : Suppose we have the following context-free grammar which accepts a list of variable initializations. Goal ::= single | Goal single single ::= VAR "=" exp ";" exp ::= VAR | INT | exp + exp Here each V AR termin ...

Script kiddies amp code monkeysthese two terms can be

Script Kiddies & Code Monkeys These two terms can be interpreted as derogatory, but they also appear as standard jargon in the workplace. What is a script kiddie? What is a code monkey? What are the differences? Does it ...

Create login form to enter user name and a password textbox

Create login form to enter user name and a password textbox to enter password, and write procedure to simulate the process of triggering the login process after hitting the Enter Key.

What are the critical issues we must think about while

What are the Critical Issues we must think about while designing a Lexical Scanner? The results of that development, e.g., discuss both process and product.

Requirementsin this assignment you will implement a

Requirements In this assignment, you will implement a lightweight version of an ArrayList class. You may refer to the Java code and documentation for guidance, but you must write the implementation yourself. Additionally ...

Where do cfos get their money newswhere do cfos get their

Where do CFOs get their money news? Where do CFOs get their money news? According to Robert Half International, 47% get their money news from newspapers, 15% get it from communication/colleagues, 12% get it from televisi ...

In linux what synchronization methods they use within the

In Linux what synchronization methods they use within the kernel, please dig into your findings for Linux.

What happens when volatility increases what does volatility

What happens when volatility increases? What does volatility percentage mean?

Can someone right the code for hangman in java the game

Can someone right the code for Hangman in java. The game would start off by asking the user if they were playing 1 person or two person hangman. If the user said 1 person then the game would print the spaces for the word ...

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As