SHOW:
|
|
- or go back to the newest paste.
1 | - | public abstract class Urzadzenie { |
1 | + | public class Pralka extends Urzadzenie { |
2 | private static int wybranyProgram = 0; | |
3 | - | public void wyswietlKomunikat(String komunikat) { |
3 | + | |
4 | - | System.out.println(komunikat); |
4 | + | public int ustawProgram(int program) { |
5 | if(program >= 1 && program <= 12) { | |
6 | wybranyProgram = program; | |
7 | } else { | |
8 | wybranyProgram = 0; | |
9 | } | |
10 | return wybranyProgram; | |
11 | } | |
12 | } | |
13 |