{\rtf1\ansi\deff0\adeflang1025
{\fonttbl{\f0\froman\fprq2\fcharset0 Times New Roman{\*\falt Thorndale};}{\f1\froman\fprq2\fcharset0 Times New Roman{\*\falt Thorndale};}{\f2\fmodern\fprq1\fcharset0 Courier New;}{\f3\froman\fprq2\fcharset0 Times New Roman;}{\f4\fswiss\fprq2\fcharset0 Arial;}{\f5\fnil\fprq2\fcharset0 HG Mincho Light J;}{\f6\fnil\fprq2\fcharset0 Arial Unicode MS;}}
{\colortbl;\red0\green0\blue0;\red0\green0\blue128;\red128\green128\blue128;}
{\stylesheet{\s1\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\snext1 Default;}
{\s2\sa120\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\sbasedon1\snext2 Text body;}
{\s3\sb240\sa120\keepn\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f4\fs28\lang1033\sbasedon1\snext2 Heading;}
{\s4\sb240\sa60\keepn\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f4\fs28\lang1033\b\sbasedon1\snext1{\*\soutlvl0} Heading 1;}
{\s5\sb240\sa60\keepn\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f4\fs24\lang1033\i\b\sbasedon1\snext1{\*\soutlvl1} Heading 2;}
{\s6\sb240\sa60\keepn\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f4\fs24\lang1033\sbasedon1\snext1{\*\soutlvl2} Heading 3;}
{\s7\sb240\sa60\keepn\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f4\fs24\lang1033\b\sbasedon1\snext1{\*\soutlvl3} Heading 4;}
{\s8\sb240\sa60\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f4\fs22\lang1033\sbasedon1\snext1{\*\soutlvl4} Heading 5;}
{\s9\sb240\sa60\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs22\lang1033\i\sbasedon1\snext1{\*\soutlvl5} Heading 6;}
{\s10\li360\ri0\fi-360\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\sbasedon1\snext10 List;}
{\s11\li720\ri0\fi-360\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\sbasedon1\snext11 List 2;}
{\s12\li1080\ri0\fi-360\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\sbasedon1\snext12 List 3;}
{\s13\cf1{\*\tlswg8236}\tqc\tx4320{\*\tlswg8236}\tqr\tx8640{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\sbasedon1\snext13 Header;}
{\s14\cf1{\*\tlswg8236}\tqc\tx4320{\*\tlswg8236}\tqr\tx8640{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\sbasedon1\snext14 Footer;}
{\s15\sb240\sa60\cf1\qc{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f4\fs32\lang1033\b\sbasedon1\snext16 Title;}
{\s16\sa60\cf1\qc{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f4\fs24\lang1033\sbasedon1\snext2 Subtitle;}
{\s17\li360\ri0\fi1\sa120\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\sbasedon1\snext17 WW-List Continue;}
{\s18\li360\ri0\fi1\sa120\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\sbasedon1\snext18 WW-Body Text 2;}
{\s19\li360\ri0\fi1\sa120\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\sbasedon18\snext19 WW-Body Text 3;}
{\s20\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\sbasedon1\snext20 Normal;}
{\s21\li720\ri0\fi0\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\sbasedon20\snext21 Body Text 2;}
{\*\cs23\cf1{\*\updnprop5801}\up10\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f0\fs24\lang1033\sbasedon26 Footnote Characters;}
{\*\cs24\cf1\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f0\fs24\lang1033 Page Number;}
{\*\cs25\cf2\ul\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f0\fs24\lang1033 Internet Link;}
{\*\cs26\cf1\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f0\fs24\lang1033 WW-Absatz-Standardschriftart;}
{\*\cs27\cf1\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f0\lang1033 WW-Absatz-Standardschriftart1;}
{\*\cs28\cf1{\*\updnprop5801}\up10\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f0\lang1033\sbasedon27 WW-Footnote Symbol;}
{\*\cs29\cf1\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f0\lang1033 WW-Default Paragraph Font;}
{\*\cs30\cf1\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f0\lang1033 WW-Page Number;}
{\*\cs31\cf1\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f0\lang1033\sbasedon29 WW-Page Number1;}
{\*\cs32\cf1\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f0\lang1033\b\sbasedon29 WW-Strong;}
}
{\info{\title 132hw04 - s03}{\author Sharon Tuttle}{\creatim\yr2001\mo1\dy23\hr10\min30}{\operator Sharon Tuttle}{\revtim\yr2003\mo3\dy8\hr1\min24}{\printim\yr2003\mo1\dy28\hr11\min42}{\comment StarWriter}{\vern6410}}\deftab720
{\*\pgdsctbl
{\pgdsc0\pgdscuse195\pgwsxn12240\pghsxn15840\marglsxn1440\margrsxn1440\margtsxn720\margbsxn720\headery0{\*\headeryb283\headerxl0\headerxr0\headeryh0}{\header \pard\plain \s13\cf1{\*\tlswg8236}\tqc\tx4320{\*\tlswg8236}\tqr\tx8640{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\ltrch\loch\fs12 {\ltrch\loch\f3 CIS 132 - HW #5\tab \tab p. {\field{\*\fldinst \\page}{\fldrslt 1}}}
\par {\ltrch\loch\f3 Spring 2003}
\par }
\pgdscnxt0 Default;}}
\paperh15840\paperw12240\margl1440\margr1440\margt720\margb720\sectd\sbknone\pgwsxn12240\pghsxn15840\marglsxn1440\margrsxn1440\margtsxn1303\margbsxn720\headery720{\header \pard\plain \s13\cf1{\*\tlswg8236}\tqc\tx4320{\*\tlswg8236}\tqr\tx8640{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\ltrch\loch\fs12 {\ltrch\loch\f3 CIS 132 - HW #5\tab \tab p. {\field{\*\fldinst \\page}{\fldrslt 1}}}
\par {\ltrch\loch\f3 Spring 2003}
\par }
\ftnbj\ftnstart1\ftnrstcont\ftnnar\aenddoc\aftnrstcont\aftnstart1\aftnnrlc
\pard\plain \s1\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\qc{\*\tlswg8236}\tx6300\ltrch\loch\fs24\b {\ltrch\loch\f3 HUMBOLDT STATE UNIVERSITY}
\par \pard\plain \s1\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\qc\ltrch\loch\fs24\b {\ltrch\loch\f3 CIS 132 - Introduction to Computer Science II - Spring 2003}
\par {\ltrch\loch\f3 Homework #5 - due Friday, March 14th,  4:30 pm}
\par {\ltrch\loch\f3 more on Lists}
\par \pard\plain \s1\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033{\*\tlswg8236}\tx1260\ltrch\loch\fs24\b 
\par \pard\plain \s1\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\ltrch\loch\fs24\b {\ltrch\loch\f3 IMPORTANT NOTE: {\b0 You must turn in the zip/floppy/cd containing your homework files to my mailbox in }NHW 234{\b0  (the departmental office) by the time and date specified above. Make sure that the zip/floppy/CD has your name on it, and that all of your HW #5 file
s are within a directory named }132hw05 {\b0 on that zip/floppy/cd.}}
\par \pard\plain \s1\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\ltrch\loch\fs24 
\par {\ltrch\loch\f3 In the same section of the course web page as this homework handout, you will find a version of a linked list, {\b Cs132LinkedList.java}, that is a subclass of the class {\b Cs132AbstractList} discussed in lecture. There's an array implementation of a list, {\b Cs132Arr
ayList.java}, that is also a subclass of {\b Cs132AbstractList}. Both of these now throw appropriate exceptions if you try to add, remove, or get inappropriately ---  note these custom exceptions, whose classes are also included. }
\par 
\par {\ltrch\loch\f3 (Note, also rather annoyingly, that once a statement MIGHT throw what is called a {\b checked}{\b0  exception, then that statement must either be inside a try-catch, OR the method containing that statement must indicate that it might throw the kind of exception that
 that statement throws. Bother. You can see what I am talking about in the {\b Cs132LinkedListTest} class also included...)}}
\par 
\par \pard\plain \s1\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033{\ltrch\loch\f3{\b0\fs24 Create a {\b doubly-linked list} implementation {\b Cs132DoublyLinkedList }(that is, with nodes having both {\b next }and {\b previous }data fields) that is also a subclass of {\b Cs132AbstractList}. In your implementation, make it easy/fast to go directly to the last node in the 
list (there are several reasonable ways to do this --- choose one...)}}
\par 
\par \pard\plain \s1\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\ltrch\loch\fs24 {\ltrch\loch\f3 To the methods you must implement, also add a new method {\b toStringInReverse()} that creates a string depiction of the list with the items in reverse order to that in which they actually occur in the list (although it doesn't actually change the list, of cour
se). Include any other classes that you also need, include an appropriate {\b Cs132DoublyLinkedListTest} class that tests it (and new method {\b toStringInReverse}()!), and include the saved text console output ({\b 132hw05_double_results.txt}) from running all of your t
ests on your new list implementation.}
\par 
\par {\ltrch\loch\f3{\b0 Also, consider the odd little class }{\b TestDiffLists.java}{\b0 ; I just wanted to see if, with the above set up, I really could use a list of either implementation where a list of type }{\b Cs132List}{\b0  was expected. Lo and behold, it was true! Modify method }{\b playingTest()}{\b0  
within this class to also try this out for your new list implementation }{\b Cs132DoublyLinkedList; }{\b0 turn in your modified }{\b TestDiffLists.java}{\b0  and the saved text console output ({\b 132hw05_play.txt}{\b0 ) from} running your new }{\b playingTest()}{\b0  version.}}
\par 
\par \pard\plain \s1\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\ltrch\loch\f2\fs24\b
\par \pard\plain \s1\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\ltrch\loch\fs24 
\par 
\par 
\par \pard\plain \s1\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\ltrch\loch\fs24\b 
\par \pard\plain \s1\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\ltrch\loch\f2\fs24 
\par \pard\plain \s1\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033 
\par \pard\plain \s1\cf1{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\aspalpha\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f3\fs20\lang1033\li360\ri0\fi-360 
\par }