Question:

Published on: 23 January, 2022

What is linear searching?

Answer:

Linear search tries to find an item in a sequentially arranged data type. These sequentially arranged data items known as array or list, are accessible in incrementing memory location.

Linear search compares expected data item with each of data items in list or array. The average case time complexity of linear search is Ο(n) and worst case complexity is Ο(n2). Data in target arrays/lists need not to be sorted.

Subjects

Trending

Write a C language function to find the in-order successor of the root of a binary tree.

View : 558

21 January, 2022

What is an Abstract Data Type? What do you mean by a Dynamic Data Structure?

View : 488

29 May, 2024

Random questions

29 May, 2024

29 May, 2024

29 May, 2024

29 May, 2024