SSVISUAL.COM

Linear Search

Linear search is a method for finding an element in a list by checking each item until you find what you're looking for.

Pseudocode

function linear_search(list,target):
  found = false
  index = 0
  FOR index = 0 to list.length
    IF target = list[index] then
      found = true
    ELSE
      index = index + 1
                  

Terminal

Current Index:

Current Value:

TARGET