Thanks to visit codestin.com
Credit goes to www.scribd.com

0% found this document useful (0 votes)
208 views2 pages

Algorithm

The document describes 3 algorithms: 1. An algorithm to calculate the total cost for tickets to a U2 concert based on the number and type of tickets purchased. 2. An algorithm to calculate tuition costs based on tuition amount, scholarships, and payment plans. It accounts for multiple scenarios. 3. An algorithm to calculate printing costs for summer photos versus other photos based on the number of each and different printing prices.

Uploaded by

Pato Martinez
Copyright
© Attribution Non-Commercial (BY-NC)
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)
208 views2 pages

Algorithm

The document describes 3 algorithms: 1. An algorithm to calculate the total cost for tickets to a U2 concert based on the number and type of tickets purchased. 2. An algorithm to calculate tuition costs based on tuition amount, scholarships, and payment plans. It accounts for multiple scenarios. 3. An algorithm to calculate printing costs for summer photos versus other photos based on the number of each and different printing prices.

Uploaded by

Pato Martinez
Copyright
© Attribution Non-Commercial (BY-NC)
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/ 2

Unit 2: Logic thinking development Algorithms Tania Moreno A01175939 Patricio Martinez A01176068 Algorithm exercises Create an algorithm

for solving the following : 1. Ticket Master is selling tickets for the next U2 concert in Monterrey. The tickets price in the VIP area is $1,000 and in the general area is $700. There is no restriction on the number of tickets a client can buy. A client could buy tickets for the General area, the VIP area or both. Create an algorithm that calculates the total pay for each client. Estimate the total pay for each client Estimate if its going to pay for both tickets. Estimate General Area Estimate VIP area Max.TotalAmount = 7 Min.TotalAmount = 1 General Area = 700 VIP = 1,000 Total Amount = (G.A * 700) + (VIP * 1,000) END

2.

You want to pay your tuition this semester and you should consider the following: o The tuition is $ 50,000 o If you use Expreso TEC, add $ 4,000. o If you have an academic scholarship, substract $ 10,000. (A) o If you have another type of scholarship, substract $ 5,000 (B) o Display the total tuition to pay.

Estimate the total payment of the Tuition Verify if have Expresso Service Verify if have Scholarship A Verify if have Scholarship B Estimate the Tuition total price with Expresso Estimate the Tuition with Scholarship A Estimate the Tuition with Scholarship B Estimate the Tuition with Scholarship A and Expresso Estimate the Tuition with Scholarship B and Expresso Tuition = 50,000 ExpressoTec = 4,000 SholarshipA = 10,000 SholarshipB = 5,000 TotalPay = Tuition + Expresso TotalPay = Tuition + Expresso - SholarshipA

Unit 2: Logic thinking development Algorithms TotalPay = Tuition + Espresso SholarshipB TotalPay = Tuition SholarshipA TotalPay= Tuition SholarshipB Calculate total value END

3. You want to print your digital photos in Costco. You bring your USB with all your pictures, but you want to
print your summer pictures in a regular size, and the rest of them in a postal size. The cost of printing in normal size $1.50 and in postal size is $2.30. You must tell the seller how much pictures are from the summer and how many dont so he could calculate the total to pay.

Estimate total amount of pictures Select the summer picture and separate them from the rest. Calculate the amount of Summer pictures Calculate the amount of the rest of the pictures. Process NS = 1.50 PS = 2.30 Total Amount = NS + PS Final Cost = (NS * SP) + (NS*RP) Output END

You might also like