Submit it as detailed on the course Resources page as "warmup."
You are going to implement some useful code for a bookstore, which they can use to keep track of inventory. A full submission for this practicum will contain 6 classes (ReadingMaterial, Book, Magazine, Bookstore, OutOfStockException, BookMain). Note BookMain is written for you.
Download warmup.tgz for test files and BookMain.java.
Unpack it with tar xzf warmup.tgz
public void sort() {
Arrays.sort(arr); // replace "arr" with the name of your array
}
You have downloaded and unpacked a directory with BookMain.java and two test files, testFile.txt, and input.txt. If your code is run as follows, it should result in the following output:
taylor@albert:~/12wk/practicum$ java BookMain testFile.txt < input.txt The Economist: $0.99 Sports Illustrated: $1.5 David Foster Wallace, Infinite Jest: $15.99 Harry S Truman, Mr. Citizen: $21.99 What would you like to buy? You are trying to buy Infinite Jest What would you like to buy? You are trying to buy Mr. Citizen What would you like to buy? You are trying to buy Mr. Citizen Out of stock! What would you like to buy? You are trying to buy The Economist Out of stock! What would you like to buy? You are trying to buy Nonexistant Out of stock! What would you like to buy?
This document was generated using the LaTeX2HTML translator Version 2008 (1.71)
Copyright © 1993, 1994, 1995, 1996,
Nikos Drakos,
Computer Based Learning Unit, University of Leeds.
Copyright © 1997, 1998, 1999,
Ross Moore,
Mathematics Department, Macquarie University, Sydney.
The command line arguments were:
latex2html -split 0 -no-navigation warmupHW.tex
The translation was initiated by Gavin Taylor on 2013-08-16