Skip to content

Instantly share code, notes, and snippets.

@parzibyte
Created August 1, 2019 15:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save parzibyte/16c7873c4f47c64b66b1d79a50185940 to your computer and use it in GitHub Desktop.
Save parzibyte/16c7873c4f47c64b66b1d79a50185940 to your computer and use it in GitHub Desktop.
/*
Mayor y menor de edad en C#
@author parzibyte.me
*/
using System;
class MayorEdad{
public static void Main(){
int edad;
Console.WriteLine("Escribe tu edad: ");
edad = Convert.ToInt32(Console.ReadLine());
if (edad >= 18){
Console.WriteLine("Mayor de edad");
}else{
Console.WriteLine("Menor de edad");
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment