Welcome to the new platform of Programmers Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use it's exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.
Sequential Search / Linear Search
Hi another question regarding the searches. (As I am studying this topic now)
Linear search is sequential search and it's [b]worst case[/b] which means the longest time it takes to search array with the [b][italic]size N[/italic][/b] is N times because it has to visit one by one. The [b]best case[/b] is [b][italic]one time[/italic][/b] if the first data was happened to be the target data to be found.
But... [red]how about [b]three-dimentional array of size N?[/b][/red]
The [b]worst[/b] and [b]best[/b]?
I dont think I've ever learn [b]three dimentional array[/b] but I assume it's like,
And I don't think in either case one-dimentinal or three-dimentional doesnt change the length of time to search? Worst for [b][italic]size N[/italic][/b] for three dimentional is still [b]N time[/b] and the best is still [b]one time[/b] I reckon?
Is that so??