| Input: | IEnumerable<TSource> |
| Optional lambda expression: | TSource => TResult |
Contains returns true if the given element is present:
using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
class Program
{
static void Main()
{
bool hasAThree = new int[] { 2, 3, 4 }.Contains(3); // true;
Console.WriteLine(hasAThree);
}
}
The output:
True
| w__w__w__.___j__a___v_a___2s__.c__o_m | Contact Us |
| Copyright 2009 - 12 Demo Source and Support. All rights reserved. |
| All other trademarks are property of their respective owners. |