Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- class MyAge
- {
- static void Main()
- {
- Console.WriteLine("Enter your current age: ");
- int CurrentAge = int.Parse(Console.ReadLine());
- if (CurrentAge < 0 | CurrentAge > 120)
- {
- Console.WriteLine("Your age is not correct!");
- }
- else
- {
- Console.WriteLine("Your age after 10 years will be: " + (CurrentAge + 10));
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement