package day09;
public class TelevisionTest {
public static void main(String[] args) {
Television tv = new Television();
tv.channel = 7;
tv.volume = 9;
tv.onOff = true;
System.out.println("텔레비전 채널은 " + tv.channel + "이고 볼륨은 " + tv.volume + "입니다.");
}
}
class Television {
int channel; //채널 번호
int volume; //볼륨
boolean onOff; //전원 상태
}
텔레비전 채널은 7이고 볼륨은 9입니다.