Livoa LogoLivoa
Start
Declare variables:
int arr[100], n, key, i, found=0
Input number of elements (n)
Input n elements into array
Input element to search (key)
Set i = 0, found = 0
Is i < n?
Is arr[i] == key?
Set found = 1
Print position (i+1)
Break loop
i = i + 1
Is found == 1?
Print "Not found"
Stop

flow

by ms

0
0 uses