Tech help
Friday, August 5, 2011
Linear search in Erlang
-module search.
-export ([search/2]).
search([],N)->
"Not Found";
search([X|L],X) ->
"Found";
search([X|L],N) ->
search(L,N).
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment