Skip to content

Instantly share code, notes, and snippets.

@valdiney
Created May 6, 2014 13:11
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 valdiney/9f539a7f6ca1cc83e07a to your computer and use it in GitHub Desktop.
Save valdiney/9f539a7f6ca1cc83e07a to your computer and use it in GitHub Desktop.
Classe Telefone, estudo simples
using System;
class Inicio
{
static void Main(string[] args)
{
MinhaClasse novo = new MinhaClasse();
Console.ReadKey();
}
}
class MinhaClasse
{
public MinhaClasse()
{
Telefone meuTelefone = new Telefone("Preto", "Android 4.1.1");
meuTelefone.Ligar("9711-4457");
}
}
class Telefone
{
private string cor;
private string so;
public Telefone(string cor, string so)
{
this.cor = cor;
this.so = so;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment