Ask Question, Ask an Expert

+61-413 786 465

info@mywordsolution.com

Ask Java Expert


Home >> Java

1: Linked Lists

In this problem you will write a class that implements an ordered list of Strings. Your class will able to add and remove elements in the list at arbitrary positions. Your implementation will use linked lists and recursion (when appropriate). Your implementation should be ecient.

Create a Java class called LinkedList that extends the LinkedListABS class. Your class must have a public constructor that has zero arguments (which creates an empty list of Strings). You may add as many private attributes and helper methods in your class as you need. You are not allowed to use an array, ArrayList, or any other container class that Java provides to store your list. You must use a linked list with the Node class provided. Mark breakdown: style:5, correctness:15

2: Copy

In the provided CopyLinkedList class, implement the copy() method as described. The resulting (copied) list should not share any memory with the input list. (That is, the list that makes up the copy must have its own Nodes.) Mark breakdown: correctness:10

3: Queue

In this problem you will implement a queue of Strings using a linked list. For this you will need to decide how to deal with adding and removing nodes (in a FIFO manner) eciently.

Your enqueue and dequeue methods should not use recursion (or iteration). A queue with less Strings in it is smaller (less than) a queue with more Strings. Two empty queues are considered the same. If two queues have the same size (bigger than 0), the order is determined alphabetically using the rst string in each queue.

Create a Java class called Queue that extends the provided QueueABS class. Your class must have a zero argument constructor that creates an empty queue. Your implementation must use linked lists with the Node class provided. Do not use recursion or iteration in your method, unless otherwise told to do so (in the toString() method for example). Your methods must be ecient.

4: Mergesort

In this problem, you will implement the mergesort sorting algorithm using linked lists.

Complete the methods in the Merge class that is provided. Your nal method (sort()) is the mergesort method. It will sort lists of Strings alphabetically. It should use both the merge() and split() methods in it. (You will also need the copy() method from the CopyLinkedList class.)

Java, Programming

  • Category:- Java
  • Reference No.:- M9134726
  • Price:- $50

Priced at Now at $50, Verified Solution

Have any Question?


Related Questions in Java

Overviewyou are required to use java se 80 and javafx to

Overview You are required to use Java SE 8.0 and JavaFX to develop a Graphical User Interface (GUI) for the FlexiRent rental property management program created in Assignment 1. This assignment is designed to help you: 1 ...

Assessment database and multithread programmingtasktask 1

Assessment: Database and Multithread Programming Task Task 1: Grade Processing University grading system maintains a database called "GradeProcessing" that contains number of tables to store, retrieve and manipulate stud ...

Chatbotscreate a small networked chat application that is

Chatbots Create a small, networked chat application that is populated by bots. Introduction On an old server park, filled with applications from the early days of the internet, a few servers still run one of the earliest ...

Assignment taskwrite a java console application that allows

Assignment task Write a java console application that allows the user to read, validate, store, display, sort and search data such as flight departure city (String), flight number (integer), flight distance (integer), fl ...

Object-oriented software development1 introduction 11

OBJECT-ORIENTED SOFTWARE DEVELOPMENT 1. Introduction 1.1 Assignment Requirement 1.2 Deliverables and Structure (what to submit) 1.3 Software Restrictions 1.4 How to score high... 1.5 Assumptions 2. System Requirements 2. ...

Assessment -java program using array of Assessment -JAVA Program using array of objects

Assessment -JAVA Program using array of objects Objectives This assessment item relates to the course learning outcomes as stated in the Unit Profile. Details For this assignment, you are required to develop a Windowed G ...

Answer the following question whats the difference public

Answer the following Question : What's the difference public inheritance and private inheritance? What can derived classes inherit from base classes? What cannot be inherited from base classes?

Project descriptionwrite a java program to traverse a

Project Description: Write a java program to traverse a directory structure (DirWalker.java) of csv files that contain csv files with customer info. A simple sample in provided in with the sample code but you MUST will r ...

Overviewyou are required to use java se 80 and javafx to

Overview You are required to use Java SE 8.0 and JavaFX to develop a Graphical User Interface (GUI) for the FlexiRent rental property management program created in Assignment 1. This assignment is designed to help you: 1 ...

Assessment socket programmingtaskwrite a java gui program

Assessment: Socket Programming Task Write a JAVA GUI program that would facilitate text chatting/exchanging between two or multiple computers over the network/internet, using the concept of JAVA socket programming. If yo ...

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As