Please help solve task 4. I'm struggling with task 4 and completed the first three tasks. Task 4 This task involves reco

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

Please help solve task 4. I'm struggling with task 4 and completed the first three tasks. Task 4 This task involves reco

Post by answerhappygod »

Please help solve task 4. I'm struggling with task 4 and
completed the first three tasks.
Task 4
This task involves recognising the methods and objects which are
being used to achieve certain program behaviours.
Modify the application so that it performs a “selection sort” or
“bubble sort”. The Clear button’s label should
be changed to Toggle Sort and the action
performed when it is clicked should be changed to toggle the type
of sort performed.
Note: The status label should indicate the
number of swaps for either sort.
The Sort button’s label should change to
indicate the current type of sort (“Selection” or “Bubble”).
A button’s label can be changed with its setLabel method.
e.g.
mybutton.setLabel("Wombat");
Original code:
SortDriver.java
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!
Post Reply