Questions
Add Instance to the Array List Instances in an Array Search for an Instance in the...



Add Instance to the Array

List Instances in an Array

Search for an Instance in the Array

Delete an Instance from the Array

Update an Instance in the Array

Save Array Elements to CSV File

Exit Program










The requirement of this assignment is to design and implement a system in Java that will manage instantiated instances of the Objects created in the User Designed Object Assignment. This is the Young Adult Object. The system should be able to add an instance of a Young Adult Object to the array, remove an instance of a Young Adult Object from the array, list all instances of Young Adult Objects in the array, Update an instance of a Young Adult object in the array and Store all instances in the array to a Comma Separated Value (CSV) File. It should also be able to load a set of starter Young Adult Objects. The task to load the starter set of objects can be a menu option or an automated process when the program starts.


The System should read data for 3 to 5 sample instances from a text file, load the data into the appropriate objects, and add the objects to the array. After loading the sample instances into the array, the system should display a menu similar to the one listed below. Your menu does not have to exactly match this one





In: Computer Science

in JAVA please Some of the characteristics of a book are the title, authors, publisher, ISBN,...

in JAVA please

Some of the characteristics of a book are the title, authors, publisher, ISBN, price, and year of publication. Design the class Book so that each object can hold the following information about a book: title, up to four authors, publisher, ISBN, price, and number of copies in stock. To keep track the number of authors, you can add a variable; Including the methods to perform various operations on the objects of book. For example, the usual operations that can be performed on the title are to show the title, set the title, and check whether a title is an actual title of the book. In the similar way, the typical operations that can be performed on the number of copies in stock are to show the number of copies in stock, set the number of copies in stock, update the number of copies in stock, and return the number of copies in stock. Add similar operations for the publisher, ISBN, book price, and authors. Add the appropriate constructors. Write the definitions of the methods of the class Book based on the instruction in a). Write a program that uses the class Book and test various operations on the objects of class Book. Say declare an array of 100 components of the type book. Some the operations that you should perform are to search for a book by its title, search by ISBN, and update the number of copies of a book.

In: Computer Science

NOTE: This assignment is for the design only Nothing you turn in should look like C/C++...

NOTE: This assignment is for the design only
Nothing you turn in should look like C/C++ code


For this assignment, we are going to design a system to Manage loans from the local public library

For this, we will need the following entities, plus collections for each of the
entities: Patrons, Books, and Loans

The data for a Book will contain at least the following:
Author
Title
ISBN Number
Library ID number
Cost
Current Status (In, Out, Repair, Lost)

You may add other data needed for your implementation as well as you will need accessor and mutator functions for the data.


The data for a Patron will contain at least:
Name (e.g. Fred Smith)
ID number (6 digits e.g. 123456)
Fine Balance
Current # of books out

You may add other data needed for your implementation as well as you will need accessor and mutator functions for the data.


The data for a Loan (The transaction entity) will contain at least the following:

Loan ID
Book ID
Patron ID
Due Date and Time
Current Status (overdue, normal)

You may add other data needed for your implementation as well as you will need accessor and mutator functions for the data.
For the collections of each of the Patrons and Books Classes identified above, you will need to include the ability to:
Add
Edit
delete
Search/Find based on appropriate criteria
Print a list of all entries in the collection
Print the details for a single entity (do a find first)

Other methods you may identify

For Loans you will need:

Check Out a book (update book and patron info as well as add a loan)
Check in a book (check for fines and update patron and book info and delete loan)
List all overdue
List all books for a particular patron
Update loan status based on the system clock
Re-Check a book
Edit a loan
Report lost (update book and charge patron book cost as well)

Other methods you may identify

You will need to verify the following

  1. Before borrowing a book, make sure Patron has no overdue books and that total books out will be <= 6 including new borrow
  2. When checking a book in, determine if fines are owed
  3. Reporting a book as lost records the cost of the book to the patrons fine balance
  4. For Loans Add = Borrow a book
    Delete = Return a book
    Edit = Re-check
  5. Also will need a
    PayFines (in Patrons)
    Report Lost (in Loans but will have to update books and patrons)
    Print a list of overdue books with patron info (in loans but will have to update books and patrons)

You will need to provide an appropriate menu system that can be multi-level if you like.

Do not attempt to provide card catalog services for allowing patrons to search for books. You may assume each book has a unique acquisition number, and you may use these numbers to refer to books borrowed and returned.

You will need to load and store the data. This can be done automatically when the program starts and ends. You should also want to store after an add, delete or edit to make sure changes to the data are preserved.

You can assume the following

Loan period is 10 days with an additional recheck of 10 days (1 recheck only)

A max of 6 books can be out to a single patron at a time

Fine rate is $0.25 per day (24 hour period)

For this design you will need to turn in the following:

A diagram set consisting of:

  1. A title page with your name, assignment, course and title
  2. a single class diagram showing only the relationships between the entities
  3. a set of six individual class diagrams showing the attributes and methods
    for each of the classes in #2
  4. Step by Step pseudo code algorithms for every method defined in every class in
    the diagram from #2. You do not need to provide pseudo code for simple accessor and mutator functions (i.e. sets and gets)
  5. A 1-2 paragraph report about your design experience.

All of these items should be gathered together, in order, in a single PDF file.

NOTE: This assignment is for the design only
Nothing you turn in should look like C/C++ code

In: Computer Science

complete this code for me, this is java question. // Some comments omitted for brevity import...

complete this code for me, this is java question.

// Some comments omitted for brevity

import java.util.*;

/*
* A class to demonstrate an ArrayList of Player objects
*/
public class ListOfPlayers
{
// an ArrayList of Player objects
private ArrayList players;

public ListOfPlayers()
{
// creates an empty ArrayList of Players
players = new ArrayList<>();
}

public void add3Players()
{
// adds 3 Player objects
players.add(new Player("David", 10));
players.add(new Player("Susan", 5));
players.add(new Player("Jack", 25));
}
  
public void displayPlayers()
{
// asks each Player object to display its contents
// - what if the list is empty?
for (Player currentPlayer : players)
currentPlayer.display();
}
  
// Q.4(a) for Week 8
public void clearPlayers()
{
/* Add code to clear all the Player objects from the ArrayList
* (ie. the list will be emptied after the operation)
*
* Hints:
* - display the list before AND after the operation to check
* if it was performed correctly
*/
  
// wrote your code here...
players.clear();
}

// Q.4(b) for Week 8
public void addPlayer()
{
/* Add code to ask user to input a name and a position,
* then use the data to add a new Player object into the
* players attribute.
*
* There is no need for any input validations.
*
* Hints:
* - use a Scanner to get user inputs
* - create a new Player object
* - use the add() method of the ArrayList class to add it into the list
*/
  
// wrote your code here...
}

// Q.4(c) for Week 8
public int findPlayer(String name)
{
int index = -1;
  
/* Add code to allow user to search for an existing Player object
* in players. The parameter is a string representing the name
* of the Player object to search. The return value is the index
* where the object is found, or -1 if the object is not found.
*
* Assume there are no duplate names in the list.
*
* Hints:
* - use a loop to search through the ArrayList
* - compare the given name to each Player's name in the list
* - use the indexOf() method to return the required index
*/
  
// wrote your code here...
  
return index;
}

// Q.4(d) for Week 8
public boolean updatePlayerName(int index)
{
boolean success = false;
  
/* Add code to allow user to modify an existing Player object
* in players. The parameter is the index to the Player object
* in the ArrayList. Your code should first check if the given
* index is within the correct range (between 0-max, where max
* if the ize of the list. If the index is not valid,
* or the player list is empty,
* print out an error message, otherwise ask the user to input
* a new name and update the Player object with that name.
* If the update operation is successful, return true (otherwise
* return false).
*
* Hints:
* - check if index is valid and list is not empty
* - if yes, use it to get at the correct Player in the list
* - update the Player's name
* - return the appropriate boolean result
*/

// wrote your code here...
  
return success;
}
  
// *** Pre-tute Task 1 for Week 9 ***
public boolean removePlayer(String name)
{
boolean success = false;
  
/* Add code to allow user to remove an existing Player object
* in players. The parameter is the name of the Player object
* to be removed. Your code should first check if th object
* with that name does exist.
*
* Your code *MUST* make a call to the findPlayer() method you
* wrote in Q.4(c) above.
*
* If the remove operation is successful, return true (otherwise
* return false, and print a simple error message).
*
* Hints:
* - use the findPlayer() method to find the position of the object
* - remove the Player if it exists
* - return the appropriate boolean result
*/
  
// wrote your code here...
  
return success;
}
  
// *** Pre-tute Task 2 for Week 9 ***
public boolean updatePlayerName(String oldName, String newName)
{
boolean success = false;
  
/* Add code to allow user to modify an existing Player object
* in players. This time the method takes 2 parameters: oldName
* is the name for an Player object to be searched for, newName
* is the name to update the object with. Your code should first
* check if the object with the oldName does exist.
*
* Your code *MUST* make a call to the findPlayer() method you
* wrote in Q.4(c) above.
*
* If the update operation is successful, return true (otherwise
* return false, and print a simple error message).
*
* Hints:
* - use the findPlayer() method to find the position of the object
* - update the Player's name with the given parameter (newName)
* - return the appropriate boolean result
*/
  
// wrote your code here...

return success;
}
}

In: Computer Science

______________ reinsurance is referred to as "obligatory" reinsurance while ______________ reinsurance is referred to as "non-obligatory"...

______________ reinsurance is referred to as "obligatory" reinsurance while ______________ reinsurance is referred to as "non-obligatory" reinsurance. proportional; non-proportional treaty; facultative non-proportional; proportional facultative; treaty

In: Finance

The following transactions apply to Hooper Co. for 2018, its first year of operations: Issued $100,000...

The following transactions apply to Hooper Co. for 2018, its first year of operations:

  1. Issued $100,000 of common stock for cash.
  2. Provided $98,000 of services on account.
  3. Collected $84,000 cash from accounts receivable.
  4. Loaned $13,000 to Mosby Co. on November 30, 2018. The note had a one-year term to maturity and a 8 percent interest rate.
  5. Paid $36,000 of salaries expense for the year.
  6. Paid a $3,500 dividend to the stockholders.
  7. Recorded the accrued interest on December 31, 2018 (see item 4).
  8. Estimated that 1 percent of service revenue will be uncollectible.
  1. Show the effects of these transactions in a horizontal statements model like the one shown below. (Enter any decreases to account balances with a minus sign. If there is no effect on the Statement of Cash Flow, leave the cell blank.)
HOOPER CO.
Horizontal Statements Model
Event No. Assets = Equity Income Statement Statement of Cash Flow
Cash + Accounts Receivable Allowance for Doubtful Accounts + Notes Receivable + Interest Receivable = Common Stock + Retained Earnings Revenue Expense = Net Income
1. not attempted + not attempted not attempted + not attempted + not attempted = not attempted + not attempted not attempted not attempted = not attempted not attempted not attempted
2. not attempted + not attempted not attempted + not attempted + not attempted = not attempted + not attempted not attempted not attempted = not attempted not attempted not attempted
3. not attempted + not attempted not attempted + not attempted + not attempted = not attempted + not attempted not attempted not attempted = not attempted not attempted not attempted
4. not attempted + not attempted not attempted + not attempted + not attempted = not attempted + not attempted not attempted not attempted = not attempted not attempted not attempted
5. not attempted + not attempted not attempted + not attempted + not attempted = not attempted + not attempted not attempted not attempted = not attempted not attempted not attempted
6. not attempted + not attempted not attempted + not attempted + not attempted = not attempted + not attempted not attempted not attempted = not attempted not attempted not attempted
7. not attempted + not attempted not attempted + not attempted + not attempted = not attempted + not attempted not attempted not attempted = not attempted not attempted not attempted
8. not attempted + not attempted not attempted + not attempted + not attempted = not attempted + not attempted not attempted not attempted = not attempted not attempted not attempted
Total 0 + 0 0 + 0 + 0 = 0 + 0 0 0 = 0 0
  1. Prepare the income statement, balance sheet, and statement of cash flows for 2018.
HOOPER CO.
Income Statement
For the Year Ended December 31, 2018
not attempted not attempted
Operating expenses
not attempted not attempted
not attempted not attempted
not attempted not attempted
Total operating expenses 0
not attempted not attempted
Non-Operating Items
not attempted not attempted not attempted
not attempted not attempted not attempted
not attempted
HOOPER CO.
Balance Sheet
As of the End of the Year 2018
Assets
not attempted not attempted
not attempted not attempted
not attempted not attempted 0
not attempted not attempted not attempted
not attempted not attempted not attempted
not attempted not attempted not attempted
Total assets 0
Liabilities not attempted
Stockholders’ equity
not attempted not attempted
not attempted not attempted
not attempted not attempted
Total stockholders’ equity 0
Total liabilities and stockholders’ equity $0

In: Accounting

________ will ALL increase a​ company's capital dividend account. Choose the correct answer. A. Life insurance​...

________ will ALL increase a​ company's capital dividend account.

Choose the correct answer.

A. Life insurance​ proceeds, net capital​ gains, and the additional refundable tax on investment income​ (ART)

B. Stock dividends received from other​ corporations, non-taxable life insurance proceeds​ & non-taxable portion of capital gains

C. Capital dividends received from other​ corporations, non-taxable life insurance proceeds​ & non-deductible portion of capital losses

D. Capital dividends received from other​ corporations, non-taxable life insurance proceeds​ & non-taxable portion of capital gains

In: Accounting

intereste calculation

Janette invested $2000 at 5% compounded annually for 5 years. How much interest did she earn at the end of the 5 year period?

In: Math

Explain the recent changes in the Federal Reserve's Open Market Operations since the year 2000. What...

Explain the recent changes in the Federal Reserve's Open Market Operations since the year 2000.

What are the principal economic goals of the Federal Reserve System?

In: Economics

social pratice in economics write an essays about pricing strategy of amazon or the consumers behavior...

social pratice in economics
write an essays about pricing strategy of amazon or the consumers behavior in a certain market of amazon company
2000-4000 words

In: Economics