Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace _2._1
- {
- class Program
- {
- static void Main(string[] args)
- {
- Console.Write("How old are you?: ");
- int age = Convert.ToInt32(Console.ReadLine());
- bool isDoorOpen;
- if (age >= 18)
- {
- isDoorOpen = true;
- Console.WriteLine("Welcome!");
- }
- isDoorOpen = false;
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement