Skip to content

Instantly share code, notes, and snippets.

@jaimeiniesta
Last active March 6, 2017 09:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jaimeiniesta/0b00e2b86133aa4f109aa7616a04065c to your computer and use it in GitHub Desktop.
Save jaimeiniesta/0b00e2b86133aa4f109aa7616a04065c to your computer and use it in GitHub Desktop.
Failed erlang example
-module(exercise).
-export([howManyEqual/2, howManyEqual/3]).
howManyEqual(X,X) ->
2;
howManyEqual(_X,_Y) ->
0.
howManyEqual(X,Y,Z) ->
howManyEqual(X,Y) + howManyEqual(Y,Z).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment