Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
//C#
public T FindInList<T>(IEnumerable<T> source, IEnumerable<T> target)
{
return source.First(target.Contains)
}
//F#
let FindInList (source : seq<_>) (target : seq<_>) = source.First(Func<_,bool>(target.Contains))
@juanplopes

This comment has been minimized.

Copy link

@juanplopes juanplopes commented Dec 29, 2010

Em c# ainda está mais elegante :)

@rodrigovidal

This comment has been minimized.

Copy link
Owner Author

@rodrigovidal rodrigovidal commented Dec 29, 2010

discordo completamente :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.