27b_Assignment_4

27b_Assignment_4 - Assignment 4 - Queues Select one option...

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

View Full Document Right Arrow Icon
Assignment 4 - Queues Select one option from the five below. All options are worth the same number of points. The more advanced options are provided for students who find the basic ones too easy and want more of a challenge. Make sure you have read and understand the Modules Information About Programming Assignments and Style Rules for Assignments before submitting this assignment. Hand in only one program, please. OPTION A (Basic): A Queue of Strings Create a Queue class using method similar to the lectures for Stack class. However, a Queue has Add() and Remove() methods in place of Push() and Pop() . Add() is similar to Push() , it places the item passed on the Queue . However Remove() takes the oldest (first in line) item off the Queue , which is the opposite of what Pop() did. If I q.Add("AA"), q.Add("BB"), q.Add("CC"), q.Add("DD"), and then call q.Remove(), it would return "AA" after the call.
Background image of page 1

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

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

This note was uploaded on 05/21/2011 for the course CIS 27B taught by Professor Unknown during the Spring '07 term at Foothill College.

Page1 / 2

27b_Assignment_4 - Assignment 4 - Queues Select one option...

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

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