{\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\sbasedon27 Footnote Characters;}
{\*\cs24\cf1\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f0\fs24\lang1033 Page Number;}
{\*\cs25\cf1\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f0\fs24\lang1033 Numbering Symbols;}
{\*\cs26\cf2\ul\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f0\fs24\lang1033 Internet Link;}
{\*\cs27\cf1\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f0\fs24\lang1033 WW-Absatz-Standardschriftart;}
{\*\cs28\cf1\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f0\lang1033 WW-Absatz-Standardschriftart1;}
{\*\cs29\cf1{\*\updnprop5801}\up10\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f0\lang1033\sbasedon28 WW-Footnote Symbol;}
{\*\cs30\cf1\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f0\lang1033 WW-Default Paragraph Font;}
{\*\cs31\cf1\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f0\lang1033 WW-Page Number;}
{\*\cs32\cf1\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f0\lang1033\sbasedon30 WW-Page Number1;}
{\*\cs33\cf1\rtlch\af6\afs24\lang255\ltrch\dbch\af5\afs24\langfe255\loch\f0\lang1033\b\sbasedon30 WW-Strong;}
}
{\info{\title 132hw10 - s03}{\author Sharon Tuttle}{\creatim\yr2001\mo1\dy23\hr10\min30}{\operator Sharon Tuttle}{\revtim\yr2003\mo4\dy24\hr1\min34}{\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 #10\tab \tab p. {\field{\*\fldinst \\page}{\fldrslt 2}}}
\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 #10\tab \tab p. {\field{\*\fldinst \\page}{\fldrslt 2}}}
\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 #10 - due Friday, May 2nd,  4:30 pm}
\par {\ltrch\loch\f3 Hashes, Hashing, and Hash Tables}
\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\li360\ri0\fi-360{\*\tlswg8236}\tx6660\ltrch\loch\f3\fs24 {\ltrch\loch\f3 Remember Java's {\b Comparable}{\b0  interface? Any class that implements }{\b Comparable}{\b0  is expected to provide a }{\b compareTo()}{\b0  method meeting certain criteria. Then, you can make an argument be of type Comparable if you don't want to limit it too much, but you need to ha
ve its instances be able to be compared to one another.}}
\par 
\par {\ltrch\loch\f3 Imagine an interface {\b Cs132Hashable}; we'd like to use it to assure that an object is suitable to be stored within a {\b Cs132HashTable} that we are going to try to create. What is needed for an object to be hashable? Well, it needs a hash function; let's call it
 {\b hash()}. It should compute and return an {\b int}, the hash value for the instance calling this method, using ONLY the key for the hashable instance. }
\par 
\par {\ltrch\loch\f3 (Hold it --- how can this be based on hash table size, then, for example? We'll have implementations of {\b Cs132HashTable}'s methods modify {\b hash()}'s return value modulo its size... I think that will work.)}
\par 
\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{\*\tlswg8236}\tx6660{\ltrch\loch\f3{\b0\i0\fs24\f3 For convenience, we'll say that this key will be of type {\b String}. And our {\b Cs132Hashable }needs one more thing: one hashes based on a {\b key} value, after all. So, {\b Cs132Hashable} also needs to assure that a class implementing it provides a {\b getKey()} method --- it s
hould return the {\b key}, of type {\b String}, of the instance calling this method.}}
\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{\*\tlswg8236}\tx6660\ltrch\loch\f3\fs24 
\par {\ltrch\loch\f3 So, interface {\b Cs132Hashable} could look like this:}
\par 
\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{\*\tlswg8236}\tx6660\ltrch\loch\f2\fs20 {\ltrch\loch\f2 /* Cs132Hashable.java 1.0                                 */}
\par {\ltrch\loch\f2 /* by Sharon Tuttle                                       */}
\par {\ltrch\loch\f2 /* last modified: 4-23-03                                 */}
\par {\ltrch\loch\f2 /*                                                        */}
\par {\ltrch\loch\f2 /* a quick'n'dirty interface for an object suitable for   */}
\par {\ltrch\loch\f2 /* being stored within an instance of a Cs132HashTable.   */}
\par 
\par {\ltrch\loch\f2 public interface Cs132Hashable}
\par {\ltrch\loch\f2 \{}
\par {\ltrch\loch\f2     /*------------------------------------------------------------}
\par {\ltrch\loch\f2      hash()}
\par {\ltrch\loch\f2      Purpose: return an int hash value for this hashable instance.}
\par {\ltrch\loch\f2               It is VERY IMPORTANT that this hash function use}
\par {\ltrch\loch\f2               ONLY this.key in computing the hash function!!!!!}
\par {\ltrch\loch\f2     --------------------------------------------------------------*/}
\par {\ltrch\loch\f2     public int hash();}
\par {\ltrch\loch\f2     }
\par {\ltrch\loch\f2     /*------------------------------------------------------------}
\par {\ltrch\loch\f2      getKey()}
\par {\ltrch\loch\f2      Purpose: return a String key --- the key value associated}
\par {\ltrch\loch\f2               with this hashable instance.}
\par {\ltrch\loch\f2     ------------------------------------------------------------*/}
\par {\ltrch\loch\f2     public String getKey();}
\par {\ltrch\loch\f2 \}}
\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{\*\tlswg8236}\tx6660\ltrch\loch\f3\fs24 
\par {\ltrch\loch\f3 Now imagine an interface {\b Cs132HashTable}:}
\par 
\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{\*\tlswg8236}\tx6660\ltrch\loch\f2\fs20 {\ltrch\loch\f2 /* Cs132HashTable.java 1.0                                */}
\par {\ltrch\loch\f2 /* by Sharon Tuttle                                       */}
\par {\ltrch\loch\f2 /* last modified: 4-23-03                                 */}
\par {\ltrch\loch\f2 /*                                                        */}
\par {\ltrch\loch\f2 /* a quick'n'dirty interface for a simple hash table;     */}
\par 
\par {\ltrch\loch\f2 public interface Cs132HashTable}
\par {\ltrch\loch\f2 \{}
\par {\ltrch\loch\f2     /*-------------------------------------------------------------}
\par {\ltrch\loch\f2      put()}
\par {\ltrch\loch\f2      Purpose: inserts the Cs132Hashable instance item into the hash}
\par {\ltrch\loch\f2               table.}
\par {\ltrch\loch\f2     --------------------------------------------------------------*/}
\par {\ltrch\loch\f2     public void put(Cs132Hashable item);}
\par {\ltrch\loch\f2               }
\par {\ltrch\loch\f2     /*-----------------------------------------------------------}
\par {\ltrch\loch\f2      get()}
\par {\ltrch\loch\f2      Purpose: returns (non-destructively) the Cs132Hashable instance}
\par {\ltrch\loch\f2               from the hash table whose key is String k. Returns null if }
\par {\ltrch\loch\f2               there is no instance with this key k.}
\par {\ltrch\loch\f2     -------------------------------------------------------------*/}
\par {\ltrch\loch\f2     public Cs132Hashable get(String k);}
\par 
\par {\ltrch\loch\f2     /*--------------------------------------------------------------}
\par {\ltrch\loch\f2      remove()}
\par {\ltrch\loch\f2      Purpose: remove ("destructively") and return the Cs132Hashable}
\par {\ltrch\loch\f2               instance from the hash table whose key is String k. }
\par {\ltrch\loch\f2               Returns null (and does not change the hash table) if }
\par {\ltrch\loch\f2               there is no such instance with this key k.}
\par {\ltrch\loch\f2     ----------------------------------------------------------------*/}
\par {\ltrch\loch\f2     public Cs132Hashable remove(String k);}
\par 
\par {\ltrch\loch\f2     /*-----------------------------------------------------------------}
\par {\ltrch\loch\f2      isEmpty()}
\par {\ltrch\loch\f2      Purpose: return true if there are no elements in the Cs132HashTable,}
\par {\ltrch\loch\f2               false otherwise.}
\par {\ltrch\loch\f2     ---------------------------------------------------------------------*/}
\par {\ltrch\loch\f2     public boolean isEmpty();}
\par 
\par {\ltrch\loch\f2     /*-------------------------------------------------------------------}
\par {\ltrch\loch\f2      size()}
\par {\ltrch\loch\f2      Purpose: returns number of elements within the Cs132HashTable}
\par {\ltrch\loch\f2     --------------------------------------------------------------------*/}
\par {\ltrch\loch\f2     public int size();}
\par 
\par {\ltrch\loch\f2     /*-------------------------------------------------------------------}
\par {\ltrch\loch\f2      clear()}
\par {\ltrch\loch\f2      Purpose: removes all elements from Cs132HashTable }
\par {\ltrch\loch\f2     ---------------------------------------------------------------------*/}
\par {\ltrch\loch\f2     public void clear();}
\par {\ltrch\loch\f2     }
\par {\ltrch\loch\f2     /*-----------------------------------------------------------------}
\par {\ltrch\loch\f2      grabContents()}
\par {\ltrch\loch\f2      Purpose: non-destructively grabs and returns an array of the items }
\par {\ltrch\loch\f2               currently within this Cs132HashTable (for testing}
\par {\ltrch\loch\f2               and debugging purposes)}
\par {\ltrch\loch\f2     --------------------------------------------------------------------*/}
\par {\ltrch\loch\f2     public Cs132Hashable[] grabContents();}
\par {\ltrch\loch\f2 \}}
\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{\*\tlswg8236}\tx6660\ltrch\loch\f3\fs24 
\par {\ltrch\loch\f3 You should do the following:}
\par 
\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{\*\tlswg8236}\tx6660\ltrch\loch\f3\fs24\b {\ltrch\loch\f3 1.\tab {\b0 Create an implementation of }Cs132Hashable{\b0  called }Cs132HashItem{\b0 . It needs at least two fields: a key field of type String, and at least one value field of your choice/type.}}
\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{\*\tlswg8236}\tx6660\ltrch\loch\f3\fs24 
\par {\ltrch\loch\f3 \tab Its constructor should take at least two arguments: a String that will become the key field value for the new Cs132HashItem instance, and additional arguments of type compatible with your other data fields, to become the value field(s)' values.}
\par 
\par {\ltrch\loch\f3 \tab Remember, when you implement {\b hash()}, that it must {\b only} use the key field to compute that hash value... You get to decide upon your own hash function! Try to make it as "good" as you can.}
\par 
\par {\ltrch\loch\f3{\b0 \tab Finally, be sure that your class includes a reasonable }{\b toString()}{\b0  method.}}
\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{\*\tlswg8236}\tx6660\ltrch\loch\f3\fs24\b 
\par {\ltrch\loch\f3 2.\tab {\b0 Create an implementation of }Cs132HashTable{\b0  called {\b Cs132FirstHashTable }using buckets and chaining (I'd advise an array of }Cs132ChainNode{\b0 's, which should look remarkably like }Cs132ListNode{\b0 's except that their data fields hold elements of type }Cs132Hashabl
e{\b0 ...)}}
\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{\*\tlswg8236}\tx6660\ltrch\loch\f3\fs24 
\par {\ltrch\loch\f3 \tab Your {\b constructor} for this implementation should accept as an argument the number of buckets that your newly-constructed hash table should have; we will not do automatic hash table expansion for this assignment... 8-).}
\par 
\par {\ltrch\loch\f3 \tab Make sure that your {\b put()}, {\b get()}, and {\b remove()} implementations modify the value returned by {\b Cs132Hashable}'s {\b hash() }method to ensure that a result is obtained within the bucket-range of your hash table. (I'd advise modifying what{\b  hash()} returns by {\b % this.n
umBuckets} --- that way, the resulting value is guaranteed to be in your hash table's range.)}
\par 
\par {\ltrch\loch\f3 \tab Tip: since {\b get()} and {\b remove()} take a String key as their arguments --- how can you call the {\b Cs132Hashable} {\b hash()} function on that?! You can build a temporary {\b dummy} instance of {\b Cs132HashItem} that only has the key field set, and then call {\b hash()} on that dum
my instance just to get the appropriate hash value for that key...}
\par 
\par {\ltrch\loch\f3 \tab Finally, your class should also include a {\b toString()} method that builds a string containing the size of the hash table, followed by a label for each bucket, followed by the contents of that bucket. Here's an example of such a string built by one implement
ation of such a method:}
\par 
\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{\*\tlswg8236}\tx6660\ltrch\loch\f2\fs20 {\ltrch\loch\f2 Cs132FirstHashTable: size: 5}
\par {\ltrch\loch\f2 bucket[0]: }
\par {\ltrch\loch\f2 bucket[1]: key: George, value: 13;}
\par {\ltrch\loch\f2 bucket[2]: key: Harold, value: 16;}
\par {\ltrch\loch\f2 bucket[3]: }
\par {\ltrch\loch\f2 bucket[4]: }
\par {\ltrch\loch\f2 bucket[5]: }
\par {\ltrch\loch\f2 bucket[6]: key: Captain Underpants, value: -3;}
\par {\ltrch\loch\f2 bucket[7]: }
\par {\ltrch\loch\f2 bucket[8]: }
\par {\ltrch\loch\f2{\b0 bucket[9]: key: Shanor, value: 31; key: Sharon, value: 13 }}
\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{\*\tlswg8236}\tx6660\ltrch\loch\f3\fs24 
\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{\*\tlswg8236}\tx6660\ltrch\loch\f3\fs24\b {\ltrch\loch\f3 3.\tab {\b0 Create a test class }{\b Cs132FirstHashTableTest }{\b0 to test your hash table implementation. (I will not require you to turn in }{\b Cs132ChainNodeTest}{\b0  or }{\b Cs132HashItemTest}{\b0  classes, although you certainly may if you wish!) }}
\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{\*\tlswg8236}\tx6660\ltrch\loch\f3\fs20 
\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{\*\tlswg8236}\tx6660\ltrch\loch\f3\fs24 {\ltrch\loch\f3 Turn in your resulting Cs132HashItem.java, Cs132ChainNode.java, Cs132FirstHashTable.java, and Cs132FirstHashTableTest.java, along with copies of the text console contents from running the methods within your Cs132FirstHashTableTest class.}
\par }