Complete this code defining a class named TV with a channel

Complete this code defining a class named TV with a channel property that the constructor nets to the value of an input parm and a get method to return it:

Solution

public class TV
{
private:
   int channel;
public:
   TV(int chan)
   {
       channel=chan;
   }
   public int getChannel()
   {
       return channel;
   }
}

 Complete this code defining a class named TV with a channel property that the constructor nets to the value of an input parm and a get method to return it: Sol

Get Help Now

Submit a Take Down Notice

Tutor
Tutor: Dr Jack
Most rated tutor on our site