0% found this document useful (0 votes)
96 views

Option B Shahine Porter

The document describes a pseudocode algorithm that accepts a price as input, performs calculations to determine the total price of buying 10 items including discounts and taxes, and outputs the final price. It declares variables to store the input price, calculated product price, discount amount, tax amount, and final price. The pseudocode then displays prompts, performs the defined calculations in steps, and displays the full final price.

Uploaded by

shahine
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
96 views

Option B Shahine Porter

The document describes a pseudocode algorithm that accepts a price as input, performs calculations to determine the total price of buying 10 items including discounts and taxes, and outputs the final price. It declares variables to store the input price, calculated product price, discount amount, tax amount, and final price. The pseudocode then displays prompts, performs the defined calculations in steps, and displays the full final price.

Uploaded by

shahine
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 4

Option B

Shahine Porter

Input Process Output

Three Numbers 1. Accept three numbers Total students who came to I.T
class.
2. Add three numbers to get
total

3. Display total

Pseudocode: I.TStudents

{This program will accept three numbers and tell the user the total amount of
students who came to I.T class. Written by Shahine Porter October, 2016}

DECLARATIONS

Variables

num1, num2, num3 - data type Integer

START

display “Enter three numbers”

read num1, num2, num3

total ← num1 + num2 + num3

display “The total amount of students are”, total

STOP
Option B

Shahine Porter

Input Process Output


Option B

Shahine Porter

Price 1. Accept price Price of buying 10 of an item

2. Multiply price by 10 to get


product.

3. Multiply the product by


0.05 to get discount price.

4. Subtract the discount


price from the product to
get total discount price.

5. Multiply the total discount


price by 0.12 to get tax.

6. Add total discount price


and tax to get full final
price.

7. Display full final price.

Pseudocode Algorithm: CostofTen

{This program will accept a price and tell the user their price of buying 10 of an item. Written by
Shahine Porter - October, 2016}

DECLARATIONS

Variables

Price - data type real

Constants

Discount = 0.05

Tax= 0.12

START

display “Enter price”

read price

product ← price * 10

discount price← Product * discount

total discount price← product - discount price

tax price← total discount price * tax

full price←total discount price + tax price

display “The total amount is”, full price


Option B

Shahine Porter

STOP

You might also like