Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- namespace EvenOrOdd
- {
- class Project1
- {
- void Main()
- {
- int x;
- Console.Write("Enter a number : ");
- x=Convert.ToInt32(Console.ReadLine());
- if(x%2==0){
- Console.Write("number {0} is an even number",x);
- }else{
- Console.Write("number {0} is an odd number",x);
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment