// ===++===
//
// OrtizOL
//
// ===--===
/*============================================================
//
// Clase: Ejemplo2Enum.cs
//
// PropĆ³sito: Uso de enumeraciones en C#.
//
============================================================*/
using System;
namespace Articulos.Cap03
{
internal class Ejemplo2Enum
{
enum Rango : long
{
Maximo = 21474483648L,
Minimo = 255L
};
public static void Main()
{
// Obtenmos los valores asignados a las constantes:
long x = (long) Rango.Maximo;
long y = (long) Rango.Minimo;
// Valores en pantalla:
Console.WriteLine("Rango.Minimo = {0}", y);
Console.WriteLine("Rango.Maximo = {0}", x);
}
}
}
Ly8gPT09Kys9PT0KLy8KLy8JT3J0aXpPTAovLwovLyA9PT0tLT09PQovKj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PQovLwovLyBDbGFzZTogRWplbXBsbzJFbnVtLmNzCi8vCi8vIFByb3DDs3NpdG86IFVzbyBkZSBlbnVtZXJhY2lvbmVzIGVuIEMjLgovLwo9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0qLwoKdXNpbmcgU3lzdGVtOwoKbmFtZXNwYWNlIEFydGljdWxvcy5DYXAwMwp7CglpbnRlcm5hbCBjbGFzcyBFamVtcGxvMkVudW0KCXsKCQllbnVtIFJhbmdvIDogbG9uZwoJCXsKCQkJTWF4aW1vID0gMjE0NzQ0ODM2NDhMLAoJCQlNaW5pbW8gPSAyNTVMCgkJfTsKCQkKCQlwdWJsaWMgc3RhdGljIHZvaWQgTWFpbigpCgkJewoJCQkvLyBPYnRlbm1vcyBsb3MgdmFsb3JlcyBhc2lnbmFkb3MgYSBsYXMgY29uc3RhbnRlczoKCQkJbG9uZyB4ID0gKGxvbmcpIFJhbmdvLk1heGltbzsKCQkJbG9uZyB5ID0gKGxvbmcpIFJhbmdvLk1pbmltbzsKCQkJCgkJCS8vIFZhbG9yZXMgZW4gcGFudGFsbGE6CgkJCUNvbnNvbGUuV3JpdGVMaW5lKCJSYW5nby5NaW5pbW8gPSB7MH0iLCB5KTsKCQkJQ29uc29sZS5Xcml0ZUxpbmUoIlJhbmdvLk1heGltbyA9IHswfSIsIHgpOwoJCX0KCX0KfQ==