Commit efe8f8df by Patryk Czarnik

Tworzenie przykładowego konta

parent 910a50c5
......@@ -19,4 +19,11 @@ public class Konto {
this.wlasciciel = wlasciciel;
}
@Override
public String toString() {
return "Konto nr " + numer + ", " + saldo + " PLN, wł. " + wlasciciel;
}
}
package p10_klasy.v3;
public class PrzykladKonto {
public static void main(String[] args) {
Osoba ala = new Osoba("Ala", "Kowalska", 30);
Konto kontoAli = new Konto(1, ala);
System.out.println(kontoAli);
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment