Create a solution algorithm that employs loops.

Assignment Help Data Structure & Algorithms
Reference no: EM13810728

Winner of the Chevy and Ford Racing Teams

Given a simple problem that requires iteration, create a solution algorithm that employs loops.

Given a simple problem that requires simple data structures, design, code, and test a solution algorithm that uses arrays. 

Given a more complex problem, develop a complete solution that includes a comprehensive statement of the problem, complete program design, and program documentation.

Scenario

There are eight cars in each team called Chevy and Ford. One car from each team races its opponent on the drag strip. Read in the racing times for the eight Chevy cars and then read in the times for the eight Ford cars. Store the times into arrays called Chevy[ ] and Ford[ ]. Then list the winner of each pair, giving the number of seconds the winner won by. At the end declare which team won based on which team had the most wins. Below is a sample match.

Enter the times for the Chevy cars: 5.4  7.2  4.0  9.1  5.8  3.9  6.2  8.1

Enter the times for the corresponding Ford cars: 5.8  6.9  3.9  9.2  5.8  3.8  6.0  8.5

And the winners are:

Chevy by 0.4 sec

Ford by 0.3 sec

Ford by 0.1 sec

Chevy by 0.1 sec

Tie !

Ford by 0.1 sec

Ford by 0.2 sec

Chevy by 0.4 sec

And the winning team is: F O R D !

  • Accept the racing times for each of the Chevy cars into the array Chevy[ ].
  • Accept the racing times for each of the Ford cars into the array Ford[ ].
  • Then declare the wining car for each race, giving the winning time in seconds.
  • If the times are identical, then declare the race was a tie.
  • Finally, declare which team won the match, assuming a tie is possible.

Be sure to think about the logic and design first (IPO chart, pseudocode, and flowchart), then code the Visual Basic program.

1-Variable List With Data Type

List all variables you will use (use valid variable names). Indicate whether the data type is string, integer, or decimal, and so on.

2-IPO Model

List the inputs, any processes/calculations, and outputs. Use the same valid variable names you used in Step 1.

3-Flowchart

Use MS Visio to create a flowchart. Paste the flowchart here, or attach it as a separate document. Use the same valid variable names you used in Step 1.

4-Pseudocode

Describe your solution using pseudocode. Use the same valid variable names you selected in Step 1.

Reference no: EM13810728

Questions Cloud

In hidebound militarism and round-robin carnage : In these day in hidebound militarism and round-robin carnage, where even that beloved ambassador of peace , the Dalai Lama says it may be necessary to counter terrorism with violence, it's fair to ask: is humanity doomed? Are we born for the battlefi..
What is the difference between a group and a team : What is the difference between a group and a team
Century american society and globalized economy : A description of at least 200 words about what do think a lawyer does, and what role a lawyer plays, and what role a lawyer should play, in the 21st century American society and globalized economy.
What subcultures are the most influential : What subcultures are the most influential within a law enforcement agency and what challenges exist with regard to police subcultures within a law enforcement agency
Create a solution algorithm that employs loops. : Given a simple problem that requires iteration, create a solution algorithm that employs loops. Given a simple problem that requires simple data structures, design, code, and test a solution algorithm that uses arrays
What were some of basquiat''s inspirations : 1) What were some of Basquiat's inspirations for his paintings? 2) How did Basquiat's paintings evolve during his short but prolific career? 3) What made Basquiat different from other artists of his generation? (Please cite evidence from the document..
The use of performance enhancing drugs : An opposition research paper on the use of performance enhancing drugs in major league baseball. How come they use it, what factors benefit ticket sales, what do crowds want to see in a game. need 5 resources APA citation.
Rationale for identified target population : Rationale for identified target population
Socially responsible investments in the northwest : Heres a bit of background information we didnt cover in our phone conversation KMS Financial Services, Inc. has been in business since 1971 and is one of the largest Northwest based independent investment firms we offer one of the widest selections o..

Reviews

Write a Review

Data Structure & Algorithms Questions & Answers

  Implement an open hash table

In this programming assignment you will implement an open hash table and compare the performance of four hash functions using various prime table sizes.

  Use a search tree to find the solution

Explain how will use a search tree to find the solution.

  How to access virtualised applications through unicore

How to access virtualised applications through UNICORE

  Recursive tree algorithms

Write a recursive function to determine if a binary tree is a binary search tree.

  Determine the mean salary as well as the number of salaries

Determine the mean salary as well as the number of salaries.

  Currency conversion development

Currency Conversion Development

  Cloud computing assignment

WSDL service that receives a request for a stock market quote and returns the quote

  Design a gui and implement tic tac toe game in java

Design a GUI and implement Tic Tac Toe game in java

  Recursive implementation of euclids algorithm

Write a recursive implementation of Euclid's algorithm for finding the greatest common divisor (GCD) of two integers

  Data structures for a single algorithm

Data structures for a single algorithm

  Write the selection sort algorithm

Write the selection sort algorithm

  Design of sample and hold amplifiers for 100 msps by using n

The report is divided into four main parts. The introduction about sample, hold amplifier and design, bootstrap switch design followed by simulation results.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd