Any number which is divisible by 2 is called as an Even number, and any number which is not divisible by 2 is called an Odd number. Examples of Even numbers are all multiples of 2 such as 2,4,6,8,10 .. and Odd numbers are 1,3,5,7,9,..

```
public static string IsEvenOrOdd(int n)
{
if (n % 2 == 0)
return "EVEN";
else
return "ODD";
}
```

**How it works:**

For any given number, we divide the number by two and check the reminder. If the remainder is 0, then it means that the number is Even otherwise Odd.

Special Numbers Conditions • Added 2 months ago

Subscribe to our Weekly Digest and get newsletters delivered directly to your inbox.

Creating AWS Lambda Layers in ASP.NET Core - Getting started

AWS
ASP.NET Core

Deploying Express.js API to AWS Lambda and API Gateway

NodeJS
Express
MySql
AWS

Securing ASP.NET Core APIs with IdentityServer4 - Getting Started

ASP.NET Core
IdentityServer4

Securing ASP.NET Core APIs with JWT Bearer using AWS Cognito

ASP.NET Core
AWS
Cognito

Implementing CQRS using Mediator in ASP.NET Core - Explained

Design Patterns
ASP.NET Core