Implement a database accounts stored in memory management

Assignment Help Database Management System
Reference no: EM13866954

Project: Managing a DB of Accounts

Your job is to implement a database (accounts stored in memory) management (access mechanisms) system as specified. Your program should loop forever to iteratively take an integer input from the user, and output accordingly with the information of the records in the database. A valid account #'s can be as large as up to 1 billion.

• Levels of completion:

1. DB of 8 records, reject new accounts when full

User input x  within ±1 billion

If account # |x| existing in DB

If account # |x| not existing in DB

Note

x < 0

Delete account # |x|

Report error, account not found

 

x > 0

Report found account #

Add   new   account # |x|

Reject when DB is full (with 8 accounts)

x = 0

Display all accounts

Sorted, from min to max

2. DB with n (≤ 256) records, LRU replacement policy

a) allow the user to initialize the size of DB (instead of 8) to be up to 256

b) no longer reject new account when DB is full: store the new account and replace the "oldest" according to Least Recently Use policy (add new account, found account both are considered as a recent Use. Display all account is not considered a Use for any account)

3. DB w/ binary search tree structure implementation

• Similarly to Level 2, allow the user to initialize the DB size (n):

• Rejecting new accounts upon full DB, 10pt. Implementing LRU replacement policy, 20pts.

• You are required to use a binary search tree structure to maintain the DB. (see https://en.wikipedia.org/wiki/Binary_search_tree)

• When displaying all the records, you will need to display the binary tree structure. For example, the tree shown here could be displayed as a list of all its nodes with two pointers (<- and ->) to the child nodes.

229_B Tree.png

All: #1 #3 #4 #6 #7 #8 #10 #13 #14
B-Tree:
<- #1 ->
#1 <- #3 -> #6
<- #4 ->
#4 <- #6 -> #7
<- #7 ->
#3 <- #8 -> #10
<- #10 -> #14
#13 <- #14 ->

Reference no: EM13866954

Questions Cloud

The debate of the cause of school and mass shootings : The debate of the cause of school and mass shootings due to either gun control laws or mental health services has been ongoing
Engineers code of ethics : Writing one page (Engineers code of Ethics). Select your preferred solution and write a brief justification for the solution of the ethical problem of Case 1033, "Ye Olde Water Main
Where management does not try to manipulate earnings : Where management does not try to manipulate earnings, there is a positive effect on earnings quality. The absence of earnings management does not, however, guarantee high earnings quality.
Write a paper about safe drinking water : Write a paper about Safe Drinking Water
Implement a database accounts stored in memory management : Your job is to implement a database (accounts stored in memory) management (access mechanisms) system as specified. Your program should loop forever to iteratively take an integer input from the user
Recognize the elements and correct use of a thesis statement : Recognize the elements and correct use of a thesis statement
Create a short story on design a new computer : Create a short story on Design a new computer
Is the death penalty a deterrent to murder : Once again, in the spirit of politics, this discussion question is in form of a debate-which means you must choose a side. Is the death penalty a deterrent to murder
Income statement into payments to employees : Given the following information, convert Robin Company 's salaries expense from its income statement into payments to employees for its statement of cash flows.

Reviews

Write a Review

Database Management System Questions & Answers

  Activity diagram for information gathering component

The prototype program should be running without errors throughout the two Phases: Information Gathering and Information Presenting.

  What are the different types of indexing supported by mysql

What are the different types of indexing supported by MySQL? What would you suggest as solutions, other than indexing, to speed up database access

  Consider the er diagram that you designed

Consider the ER diagram that you designed for the Prescriptions-R-X chain of pharmacies in Exercise 2.7. De?ne relations corresponding to the entity sets and relationship sets in your design using SQL.

  The database dish.xlsx contains a transaction history

The database Dish.xlsx contains a transaction history describing more than 4,000 purchases of detergent

  Design and build a small database application

Refine research and analysis skills through locating, selecting and compiling a higher-level research essay.

  Recognize business processes evaluated-dw-bi application

Identify the business processes which would be evaluated and tracked with a DW/BI application and state your reasoning or justification for including these in the DW/BI.

  Examine the use of databases in organization

Create a 2-3 page (350 words per page) examining the use of databases in organization. Explain what database applications are utilized (Microsoft Access, DB2, Oracle, etc.).

  Advantages and disadvantages of joins and nested queries

One side effect of normalization is that you often need more than one table to get meaningful results. For example, you may have a table that includes a list of parts and the ID number for the vendor of each part. T

  Questionethical and legal considerations in marketing

questionethical and legal considerations in marketing intellectual property and product safetyprepare a paper in which

  Write a 2 page research paper excluding the title page on

write a 2 page research paper excluding the title page on the turing and von neumann models. compare and contrast each

  Define responsibility for database administration

Write a paper discussing what professional organizations you might join, and websites you might visit, that would provide insight into a career that includes responsibility for database administration

  An entity-relationship diagram for a database

an Entity-Relationship diagram for a database

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd