1446T - TP4 - WEEK 8 - Tugas Personal ke-4 Minggu 8 Review...

Info icon This preview shows pages 1–3. Sign up to view the full content.

View Full Document Right Arrow Icon
Tugas Personal ke-4 Minggu 8 Review Questions: 1. What is the difference between ArrayList and Vector? 2. What is the return type of a main method? 3. A call to a method with a void return type is always a statement itself, but a call to a value-returning method is always a component of an expression. Is this statement true or false? 4. What does JVM do when an exception occurs? How do you catch an exception? 5. What is a checked exception and what is unchecked exception? Programming Exercise: A program is required to receive a set of data that inserted by a user. The data contains with item_id, item_name, and the price. After the user inserted all of the data, the program shows some menus: 1. Show the data 2. Add data 3. Remove the data 4. Update the data 5. Exit If a user chooses number 1, the program will show the data as the example below: Item_id item_name price 1 pencil 10 $ 2 book 15 $ 5 eraser 5 $ If a user chooses number 2, the program will ask a user to insert a new data (item_id, item_name, and price). The same item_id should not be inserted twice (no redundant item_id). The new data will be inserted after a user finished inserting the data.
Image of page 1

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

View Full Document Right Arrow Icon
If a user chooses number 3, the program will ask the user to insert the item_id wanted to be deleted.
Image of page 2
Image of page 3
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern