Az allomanyokban van a feladatok pdf, es a mai orai munka
This commit is contained in:
67
20231211/ConsoleApp1/Program.cs
Normal file
67
20231211/ConsoleApp1/Program.cs
Normal file
@@ -0,0 +1,67 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace ConsoleApp1
|
||||
{
|
||||
class Felhasznalo
|
||||
{
|
||||
private string e_mail, jelszo, felhnev;
|
||||
|
||||
public Felhasznalo(string em, string fn, string pw)
|
||||
{
|
||||
E_mail = em;
|
||||
Jelszo = pw;
|
||||
Felhnev = fn;
|
||||
}
|
||||
|
||||
public string E_mail
|
||||
{
|
||||
get { return this.e_mail; }
|
||||
set { this.e_mail = value;}
|
||||
}
|
||||
|
||||
public string Jelszo
|
||||
{
|
||||
get { return this.jelszo; }
|
||||
set { this.jelszo = value; }
|
||||
}
|
||||
public string Felhnev
|
||||
{
|
||||
get { return this.felhnev; }
|
||||
set { this.felhnev = value; }
|
||||
}
|
||||
|
||||
private string tulajdonsag;
|
||||
|
||||
public string Tulajdonsag
|
||||
{
|
||||
get { return this.tulajdonsag; }
|
||||
set { this.tulajdonsag = value;}
|
||||
}
|
||||
public void Hozzaad()
|
||||
{
|
||||
Console.WriteLine("Adj meg egy tulajdonságot!");
|
||||
Tulajdonsag = Console.ReadLine();
|
||||
}
|
||||
|
||||
public void Kiir()
|
||||
{
|
||||
Console.WriteLine($"A felhasználó nagyon {Tulajdonsag}.");
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
class Program
|
||||
{
|
||||
static void Main(string[] args)
|
||||
{
|
||||
Felhasznalo felh = new Felhasznalo("asd@gmail.com", "KukaLadik", "F3lt0rh3t3tl3n");
|
||||
|
||||
felh.Hozzaad();
|
||||
felh.Kiir();
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user