In C#, instead of doing if(index == 7 || index == 8), is there a way to combine them? I\'m thinking of something like if(index == (7, 8)).
if(index == 7 || index == 8)
if(index == (7, 8))
Do u need something like that
int x = 5; if((new int[]{5,6}).Contains(x)) { Console.WriteLine("true"); } Console.ReadLine();