Program to records name-bounty and difficulty for ten target, Programming Languages

You have been employed by a bounty hunter to create hit list (yes... you better do this right). Create a Hit List program that can records the name, bounty, and difficulty for ten targets.

Tasks:

1. Create a new HitList.pas file in your Documents/Code/Lab6 directory.

2. Implement the basic program structure, along with an empty Main procedure.

3. Copy in your User Input functions to make it easy to read input from the user.

4. Create a new Target record with the following details. Use chapter 7 of the text to determine how to code this.

Listing 1: Structure for the Target record

5. Create a ReadTarget function that returns a Target from values entered at the Terminal Read name, bounty, and difficulty from the user and store in the result

6. Create a PopulateHitList procedure. This will be passed an array of Target values. Have it read in a Target for each element in the array (using ReadTarget).

7. Create a hits local variable in Main, this will store 10 Target values.

8. Populate the hits variable using the PopulateHitList procedure.

9. Create a PrintHitList procedure. This will be passed an array of Target values, that it will print to the Terminal. Show in the format "name : $bounty (difficulty)".

10. Compile and run your program in the Terminal, check that all of the values you enter are printed out.

Extension:

1. Create a SortHitList procedure that sorts the results so that the Target with the highest bounty is the first in the array. If two Targets have the same bounty, sort them so that the one with the smaller difficulty comes first.

Posted Date: 2/19/2013 4:13:35 AM | Location : United States







Related Discussions:- Program to records name-bounty and difficulty for ten target, Assignment Help, Ask Question on Program to records name-bounty and difficulty for ten target, Get Answer, Expert's Help, Program to records name-bounty and difficulty for ten target Discussions

Write discussion on Program to records name-bounty and difficulty for ten target
Your posts are moderated
Related Questions
Design an application that opens and analyses word files. Requirements: Create an application that analyses text documents. It should open a text file, read each word into an ap

Write a Program to Show Twenty Ellipses 1. Write a program to show twenty ellipses which move away from the mouse pointer. Their initial locations should be random.

The software development team identified the following classes based on the analysis of given requirements: Product, Employee, ProductList, Supplier. 1.  Identify the relationsh

How and where to start to develop a preprocessor for java

Write your own version of the strcmp function string_compare. Supply a main program that will test each of the 3 differing outcomes. int string_compare(char *s, char *t); retu

Each of the following two procedures defines a method for adding two positive integers in  terms of the procedures inc, which increments its argument by 1, and dec, which decrement

would you like to see some of my code. I am trying to do an add friend request. when I view my friends page I click on the add button. with ajax I want the script to send over the

Problem Specification I/O programming is the \bread and butter", the raison d'etre, of microcontrollers. After all, our definition of a microcontroller is \a microprocessor wit

1- Allocate array with 32bit 100 element 2- Prompt the user to enter the maximum or the upper bound of the random value 3- Read the value and use it generate random numbers to init

Software and sales assingment I keep get a syntax error