Skip to content

Instantly share code, notes, and snippets.

@jesuscampos
Last active December 5, 2017 19:09
Show Gist options
  • Select an option

  • Save jesuscampos/b8bcb04119eec3ab32007b170ca1ddeb to your computer and use it in GitHub Desktop.

Select an option

Save jesuscampos/b8bcb04119eec3ab32007b170ca1ddeb to your computer and use it in GitHub Desktop.
private decimal precio;
public decimal Precio
{
get
{
return precio;
}
set
{
if (value > MAX_VALUE)
{
throw new ArgumentOutOfRangeException("Cantidad máxima excedida");
}
else if (value < 0)
{
precio = value;
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment