mirror of
https://github.com/TheAlgorithms/C
synced 2024-11-22 05:21:49 +03:00
Update interpolation_search.c
This commit is contained in:
parent
ad3b1c37fe
commit
df99ef4cb1
@ -30,7 +30,7 @@ int main()
|
||||
// be conducted.
|
||||
int arr[] = {10, 12, 13, 16, 18, 19, 20, 21, 22, 23,
|
||||
24, 33, 35, 42, 47};
|
||||
int n = sizeof(arr)/sizeof(arr[0]);
|
||||
int n = sizeof(arr)/sizeof(arr[0]); //To get length of an array
|
||||
|
||||
int x = 18; // Element to be searched
|
||||
int index = interpolationSearch(arr, n, x);
|
||||
|
Loading…
Reference in New Issue
Block a user