I NEED THIS DONE RIGHT FOR A GUARANTEE THUMBS UP. THANK YOU. Hello don't worry about the MySortingList.class I will comp

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

I NEED THIS DONE RIGHT FOR A GUARANTEE THUMBS UP. THANK YOU. Hello don't worry about the MySortingList.class I will comp

Post by answerhappygod »

I NEED THIS DONE RIGHT FOR A GUARANTEE THUMBS UP. THANK YOU. Hello don't worry about the MySortingList.class I will complete it, I just want to know the steps to it and ill complete it. Thank you
I Need This Done Right For A Guarantee Thumbs Up Thank You Hello Don T Worry About The Mysortinglist Class I Will Comp 1
I Need This Done Right For A Guarantee Thumbs Up Thank You Hello Don T Worry About The Mysortinglist Class I Will Comp 1 (86.28 KiB) Viewed 25 times
package lab4;
public class MyOrganizingBag<T> implements OrganizingBagInterface<T> {
@Override
public boolean isEmpty() {
// TODO Auto-generated method stub
return false;
}
@Override
public int getSize() {
return 0;
// TODO Auto-generated method stub
}
@Override
public boolean add(T t) {
// TODO Auto-generated method stub
return false;
}
@Override
public T remove() {
// TODO Auto-generated method stub
return null;
}
@Override
public int find(T t) {
// TODO Auto-generated method stub
return 0;
}
@Override
public boolean get(T t) {
// TODO Auto-generated method stub
return false;
}
@Override
public String printBag() {
// TODO Auto-generated method stub
return null;
}
}
Goal: To test your proficiency of linked nodes and utilize a move to front technique for rearranging nodes. MAKE SURE TO ONLY TURN IN THE .java FILE Part 1: Create the Node class - 1 pts. This class will contain all neccecery information about the node of the bag that you will be creating. This class will be a private nested class within your MySortingList class. Remember that nodes typically contain just the data, and a way to reach the next node in the bag. Part 2: Create the MyOrganizingBag - 17 pts. Here you will implement the bag using an interface provided to you, the methods will include the following- • . isEmpty()-checks if bag is Empty 0.5 pts. getSize() - returns the number of objects in the Bag 0.5pts. add(Tt) - this will add "t" to the end of the bag (before it didn't matter where it was added). 2 pts. • remove() - will remove the value at the beginning of the bag and return the value contained within it. - 1 pt. • find (Tt) - will find and return the index of object t if it exists. - 5 pts. get(Tt) - will get the value and return it if it exists within the bag. That item will then be moved to the beginning of the bag. - 5 pts. printBag() -create a string of the bag in a clean readable manner, do not actually print the bag, you should have no print methods here-3 pts. You have already seen an implementation of a node-based bag, both in class and in the previous lab, the only methods that are new in this lab are find() and get(). Additional requirements: 2 pts. Commented code 1pt. Clean readable code (if there were no comments can I still understand what each variable and method is for? No magic numbers. Use best coding practices.) 1 pt.
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!
Post Reply