/** * QUESTION 6: LinkedLists (10 marks) * * @return The number of unique doubles in the list. return 0 i

Business, Finance, Economics, Accounting, Operations Management, Computer Science, Electrical Engineering, Mechanical Engineering, Civil Engineering, Chemical Engineering, Algebra, Precalculus, Statistics and Probabilty, Advanced Math, Physics, Chemistry, Biology, Nursing, Psychology, Certifications, Tests, Prep, and more.
Post Reply
answerhappygod
Site Admin
Posts: 899603
Joined: Mon Aug 02, 2021 8:13 am

/** * QUESTION 6: LinkedLists (10 marks) * * @return The number of unique doubles in the list. return 0 i

Post by answerhappygod »

/** * QUESTION 6: LinkedLists (10 marks) * * @return The number of unique doubles in thelist. return 0 if the list is * empty. * * * Example: * * If head -> 4.5-> 5.2 -> 4.5 -> 6.4 -> 1.2 -> 1.2 -> null * * then countUniqueshould return 2 (since 5.2 and 6.4 are unique). * */ public int countUnique() { // To be completed return -1; }
cant use hash sets
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!
Post Reply