More So what about the T<X[1] case? 

Forum: Com Sci 221, U Chicago, Autumn 2001, Old Classwork
Re: News Assignment #4 due Monday, 22 October (Mike O'Donnell)
Re: Question Question about B (Kristina Matesa)
Re: Feedback Notice "B<J" in the problem statement (Mike O'Donnell)
Date: 2001, Oct 19
From: Kristina Matesa kmatesa

Okay, I think I got it, but just making sure. Is this the behavior we want if I have the following:

1, 2, 3, 3, 3, 7, 7, 9, 9, 10, 11, 11, 13, 15, 17, For which value do you wish the search the above array? 0 Index of 0 is: 0 Press any key to continue

I know "index of 0" is badly worded, but what I mean is the spot where elements to the left in the array are equal to or less than the given value, and elements to the right are strictly greater than.

So if the value we are searching for is less than all of the elements of the array, in that case, our "B" would be 0, since that is the spot where all the values to the right would be strictly greater. (????)

Thanks, Kristina


Messages

1. Agree B=0 is correct in this case by Mike O'Donnell, 2001, Oct 20

to: "So what about the T<X[1] case?"