lab2_001 - 15-121 FALL 2009 [CORTINA]LAB 2In this lab, you...

Info iconThis preview shows pages 1–4. Sign up to view the full content.

View Full Document Right Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: 15-121 FALL 2009 [CORTINA]LAB 2In this lab, you will complete a class to represent a set of television channels for a cable TV system. The class will read the television channel data from a text file. Each television channel in the file consists of a number followed by a name on the same line. For example: 101 National Geographic ChannelThe first line in the file contains the number of channels stored in the file. Click HEREfor a copy of the data file to view. NOTE: The channels in the file are already in alphabetical order based on channel name. EXERCISESDownload the CableTV.zipproject folder. Inside there is a class named Channelwhich represents a single TV channel with two fields, a number and a name, along with the usual accessors and mutators. 1.In the class named CableSystem, the constructor has one parameter specifying the name of the data file that contains the television channel data. The constructor opens the file and loads the data into an array leaving no empty cells. If the file is not there, it reports an empty cells....
View Full Document

This note was uploaded on 12/19/2009 for the course CS 121 taught by Professor Reid-miller during the Spring '09 term at Carnegie Mellon.

Page1 / 6

lab2_001 - 15-121 FALL 2009 [CORTINA]LAB 2In this lab, you...

This preview shows document pages 1 - 4. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online