HW7 - HW#7 SPECS = In your HW7 program code, you must use...

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

View Full Document Right Arrow Icon
HW#7 SPECS ========== In your HW7 program code, you must use ONLY Linked List data structures, i.e. use the List.java file from the online lecture notes. You must NOT use non-List data structures (e.g., arrays, etc). (Unless, they are only used to store Lists, such as described in the "Extra Hint" below.) For ease, you can change the List class's "head" and "tail" property, to "public" instead of "private". (If your HW7 uses .head and .tail, I'll run your HW7 with "public" properties.) Speed requirements: For each of the "sample inputs" shown later in this file, your program must compute and output the answer in less than 5 seconds (on rohan). (It's possible to make each of them run in less than 1 sec.) If your code is slow but works, you will get partial credit, of course. HINT: Don't compute and check all possible combinations after the user has inputted his or her data. There are over 31 billion combinations, so examining them individually will result in large running times. Instead, you can decrease your program's running time by figuring out clever ways to decrease the number of combinations you must examine. E.g., you can speed up your program's running time by pre-computing and storing relevant information ahead of time (in List data structures). SAMPLE RUN:
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 08/17/2011 for the course CS 108 taught by Professor Ivanbajic during the Spring '09 term at San Diego.

Page1 / 4

HW7 - HW#7 SPECS = In your HW7 program code, you must use...

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