In Sect. 15.5 a set called regNums was created to store a collection of car registration numbers. (a) Write a fragment of code that makes use of an enhanced for loop to display all registrations...

In Sect. 15.5 a set called regNums was created to store a collection of car registration numbers. (a) Write a fragment of code that makes use of an enhanced for loop to display all registrations ending in ‘S’. (b) Write a fragment of code that makes use of a forEach loop to display all registrations ending in ‘S’. (c) Write a fragment of code, which makes use of the iterator method, to remove all registration numbers ending in ‘S’.

May 19, 2022
SOLUTION.PDF

Get Answer To This Question

Submit New Assignment

Copy and Paste Your Assignment Here