CS 411 Fall 2025
 > 
Assignment 4 (Various)
CS 411 Fall 2025
Assignment 4 (Various)
Assignment 4 is due at
5 pm Tuesday, October 28.
It is worth 85 points.
Procedures
This assignment is to be done individually.
Turn in your answers to the exercises below on the
UA Canvas
site,
under Assignment 4 for this class.
  
  - Your submission must consist of
  a PDF file
  with your name
  near the top of the first page.
- I may not look at your homework submission immediately.
  If you have questions,
  e-mail me.
Exercises (A–J, 85 pts total)
Do each of the following exercises.
“L 2.4/9”
means section 2.4 in the
Levitin text,
exercise #9.
- L 2.4/9.
 Be sure to show your recurrence and its exact solution.
- L 3.2/8.
 “Design an algorithm”
means that I want a precise enough description that I could
write code based on it.
(You may suppose that I am a reasonably competent programmer.)
- L 4.5/13.
 Be careful with this one!
Whatever algorithm you come up with,
I strongly suggest that you try it out on some actual data.
In particular, you should construct a sizable matrix
that meets the required conditions,
and in which the value being searched for occurs exactly once,
somewhere in the middle of the matrix.
Does your algorithm find it?
And is it really \(O(n)\)?
- L 5.1/5.
- L 5.3/5.
 In each part,
give a list of the values in the order they will be visited.
- L 6.1/8.
- L 6.6/6.
- L 7.1/7.
 In part b, describe an algorithm.
- L 7.1/10.
- L 7.3/3.