EC327 Introduction to Software Engineering HW #4 – Due Monday Nov. 16, 2009 Score: [ ] Grader: [ ] Name: ___________________ BUID: ___________________ Homework guidelines: You are expected to do individual work on homework assignments. Homework should be handed in during class on the due date. Please use extra sheets as necessary and staple them to this grading sheet.Problem 1 [15 pts] Chapter 12 – Problem 4, please hand in a typescript of output as well. Problem 2 [85 pts] Write a program that generates and sorts an array of 100 random integers which range between 1 and 998. Your program should display the unsorted and sorted numbers and then prompt the user to enter a number in the range of 0 through 999. If this number exists, then the index of the number should be returned. If on the other hand the number does not exist, then the indices and the values of the two closest numbers should be returned instead, unless the number is a boundary condition (see Questions 5 & 6 below), in which case you should take an action that you think is appropriate.
This is the end of the preview.
access the rest of the document.