ExtensionMethod.NET Home of 880 C#, Visual Basic, F# and Javascript extension methods
Finds if the int is the specified range
public static bool IsInRange(this int target, int start, int end) { return target >= start && target <= end; }
int foo = 4; Console.WriteLine(foo.IsInRange(2,6)); // output 'True'
Author: Marwan Aouida
Submitted on: 15 okt. 2010
Language: C#
Type: System.Int32
Views: 7522