TheAlgorithms/C++ 1.0.0
All the algorithms implemented in C++
|
Linear search algorithm More...
#include <cassert>
#include <iostream>
Go to the source code of this file.
Functions | |
int | LinearSearch (int *array, int size, int key) |
for IO operations | |
static void | tests () |
Self-test implementations. | |
int | main () |
Main function. | |
Definition in file linear_search.cpp.
int LinearSearch | ( | int * | array, |
int | size, | ||
int | key ) |
for IO operations
for assert
[Algorithm implementation for linear search]
[in] | array | array to search in |
[in] | size | length of array |
[in] | key | key value to search for |
Definition at line 21 of file linear_search.cpp.
int main | ( | void | ) |
Main function.
Definition at line 65 of file linear_search.cpp.
|
static |
Self-test implementations.
Definition at line 37 of file linear_search.cpp.