Database System Concepts
7th Edition
ISBN: 9780078022159
Author: Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher: McGraw-Hill Education
expand_more
expand_more
format_list_bulleted
Question
Debug the
· If the list is empty, it should print “There are no users.”
· If the user is “Admin,” the program should print “Hello all powerful one.”
· Otherwise, for normal users, it should print “You are a normal user.” Test the program with an empty list to confirm correct operation for that case.
Expert Solution
This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
Step by stepSolved in 4 steps with 2 images
Knowledge Booster
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.Similar questions
- Write a hangman game that randomly generates a word and prompts the user to guess one letter at a time, as shown in the sample run. Eachletter in the word is displayed as an asterisk. When the user makes a correct guess, the actual letter is then displayed. When the user finishes a word, display the number of misses and ask the user whether to continue playing. Create a list to store the words, as follows:# Use any words you wishwords = ["write", "that", "program", ...]arrow_forwardA drinks list is searched for Milk using binary search. Drinks list: ( Chai, Cocoa, Coffee, Espresso, Juice, Latte, Milk, Smoothie, Tea ) What is the first drink searched? What is the second drink searched?arrow_forwardof range. 3. Use the method swap that you wrote in Exercise 2 to write a method that reverses the order of the items in a list alist.arrow_forward
- C++ Program This assignment consists of 2 parts. 1. Append Process: Create a Linked List that will store integers. Using the provided getData() method (See below), append 20 numbers to the Linked List. After loaded, display the data. Start with the Head of the list. Prompt for user to proceed. 2. Insert Process: Delete the contents of the Linked List in part 1. Using the provided getData() method, insert 20 numbers into the list and place them in the list in numerical order (1..X). Do not allow duplicates to be in the list. Hint: Do not allow a duplicate to count as a member of the 20. After loaded, display the data per line in order, starting with the Head of the list. Display the content with a leading increasing number 1- 20. i.e. 11 13 14 20 The result should be a naturally sorted. Do not use the STL list container for this exercise. Use the features described in section - Linked List Operations. Using a Class to manage the linked list as shown in section is…arrow_forwardWrite a python hangman program Modify your program so that the following functionality is added:1. Instead of selecting the word from a hard coded list, incorporate problem2 so that thelist is read from a file, then a word is randomly selected from this list.2. when the game ends, the following information should be outputted to a new file:● the word● the state of the hangman● if the user won or lostExample outputs:quokkaO\||You won!kangarooO\|/|/ \You lostarrow_forwardThe for construction is a loops that iteratively processes a given list. Consequently, it works so long even though there are objects to process. What about this claim: true or false?arrow_forward
- Java code Screenshot and output is must sample input is givenarrow_forwardImplement a function void printAll(void) to print all the items of the list.arrow_forwardSuppose names is an ABList containing 10 elements. The call names.add(0, "George") results in: A. an exception being thrown. B. a 10-element list with "George" as the first element. C. an 11-element list with "George" as the first element. D. a single element list containing "George". E. None of these is correct.arrow_forward
- Instructions Write a program to test various operations of the class doublyLinkedList. Your program should accept a list of integers from a user and use the doubleLinkedList class to output the following: The list in ascending order. The list in descending order. The list after deleting a number. A message indicating if a number is contained in the list. Output of the list after using the copy constructor. Output of the list after using the assignment operator. An example of the program is shown below: Enter a list of positive integers ending with -999: 83 121 98 23 57 33 -999 List in ascending order: 23 33 57 83 98 121 List in descending order: 121 98 83 57 33 23 Enter item to be deleted: 57 List after deleting 57 : 23 33 83 98 121 Enter item to be searched: 23 23 found in the list. ********Testing copy constructor*********** intList: 23 33 83 98 121 ********Testing assignment operator*********** temp: 23 33 83 98 121 Your program should use the value -999 to denote the end of the…arrow_forward4 ete t of With the following lists: list1 = [x + y for x in ['a', 'b', 'c'] for y in ['1', '2', '3']] list2 = [[x + y for x in ['a', 'b', 'c']] for y in ['1', '2', '3']] which option is true? Select one: A. len(list1)> len(list2) B. 'a1' is an element (or subelement) for list1 whereas '1a' is for list2 C. list1 and list2 will error because numbers and letters cannot be added. D. Both A and B are true.arrow_forwardIn DrRacket, which of the following is the signature of primitive append? A) List List -> ListOfList B) List List -> List C) ListOfList -> ListOfList D) List List ... List -> ListOfList E) List List ... List -> Listarrow_forward
arrow_back_ios
SEE MORE QUESTIONS
arrow_forward_ios
Recommended textbooks for you
- Database System ConceptsComputer ScienceISBN:9780078022159Author:Abraham Silberschatz Professor, Henry F. Korth, S. SudarshanPublisher:McGraw-Hill EducationStarting Out with Python (4th Edition)Computer ScienceISBN:9780134444321Author:Tony GaddisPublisher:PEARSONDigital Fundamentals (11th Edition)Computer ScienceISBN:9780132737968Author:Thomas L. FloydPublisher:PEARSON
- C How to Program (8th Edition)Computer ScienceISBN:9780133976892Author:Paul J. Deitel, Harvey DeitelPublisher:PEARSONDatabase Systems: Design, Implementation, & Manag...Computer ScienceISBN:9781337627900Author:Carlos Coronel, Steven MorrisPublisher:Cengage LearningProgrammable Logic ControllersComputer ScienceISBN:9780073373843Author:Frank D. PetruzellaPublisher:McGraw-Hill Education
Database System Concepts
Computer Science
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:McGraw-Hill Education
Starting Out with Python (4th Edition)
Computer Science
ISBN:9780134444321
Author:Tony Gaddis
Publisher:PEARSON
Digital Fundamentals (11th Edition)
Computer Science
ISBN:9780132737968
Author:Thomas L. Floyd
Publisher:PEARSON
C How to Program (8th Edition)
Computer Science
ISBN:9780133976892
Author:Paul J. Deitel, Harvey Deitel
Publisher:PEARSON
Database Systems: Design, Implementation, & Manag...
Computer Science
ISBN:9781337627900
Author:Carlos Coronel, Steven Morris
Publisher:Cengage Learning
Programmable Logic Controllers
Computer Science
ISBN:9780073373843
Author:Frank D. Petruzella
Publisher:McGraw-Hill Education