Course Solutions Uncategorized (Solved) : Java Using 2 Text Files Interesttxt Watching Cbs20 Abc22 Wishlist Abc2030 Pbs21 Cbs22 Tvgu Q30557625 . . . .

(Solved) : Java Using 2 Text Files Interesttxt Watching Cbs20 Abc22 Wishlist Abc2030 Pbs21 Cbs22 Tvgu Q30557625 . . . .

 

In java using the 2 text files

Interest.txt

Watching
CBS20
ABC22
Wishlist
ABC2030
PBS21
CBS22

TVGuide.txt

CBS20 Big_Brother
S 20.00
E 21.00

NBC20 World_Of_Dance
S 20.00
E 22.00

ABC2030 The_Goldbergs
S 20.30
E 21.00

ABC21 Modern_Family
S 21.00
E 21.30

PBS21 Wonders_Of_Mexico
S 21.00
E 22.00

FOX21 Gordon_Ramsay’s_24_Hours_To_Hell_And_Back
S 21.00
E 22.00

NBC21 World_Of_Dance
S 20.00
E 22.00

ABC2130 American_Housewives
S 21.30
E 22.00

CBS22 Criminal_Minds
S 22.00
E 23.00

ABC22 Shark_Tank
S 22.00
E 23.00

SOLUTION TO PART I AND II

Part – I

—————————————————————————————————————————————

public interface Watchable{

   String isOnSameTime(TVShow s);

}

—————————————————————————————————————————————

Part – II

—————————————————————————————————————————————

package assignment7;

import java.util.Scanner;

public class TVShowimplements Watchable {

   private String showID;

   private String showName;

   privatedouble startTime;

   privatedouble endTime;

  

   public String getShowID(){

       returnshowID;

   }

   public voidsetShowID(String showID) {

      this.showID = showID;

   }

   public String getShowName(){

       returnshowName;

   }

   public voidsetShowName(String showName) {

      this.showName =showName;

   }

   publicdouble getStartTime() {

       returnstartTime;

   }

   public voidsetStartTime(double startTime) {

      this.startTime =startTime;

   }

   publicdouble getEndTime() {

       returnendTime;

   }

   public voidsetEndTime(double endTime) {

      this.endTime =endTime;

   }

  

  

OR

PayPal Gateway not configured

OR

PayPal Gateway not configured

Leave a Reply

Your email address will not be published. Required fields are marked *

Related Post