Answers for "c# math odd number checl"

C#
1

odd or even in c#

if(num %2 == 0){
  Console.WriteLine("Number is even")
}else{
  Console.WriteLine("Number is odd")
}
Posted by: Guest on October-29-2020
-1

c# if int is even

int i = 5;
if (i % 2 == 0)
{
	// even
}
else
{
	// odd
}
Posted by: Guest on September-12-2020

C# Answers by Framework

Browse Popular Code Answers by Language