I couldn't solve it

I couldn't solve it

*A customer who wants to apply for getting a car license should provide information about the brand of the car. *Then the customer receives a request ID from the office. *The customer's request (represented by his/her ID) is sent to the specialized employee. *Each employee in the oce is specialized in only one brand. Thus, according to the brand of the car, the request is sent to one of the employees. *After receiving all the requests to be processed, the employee processes them and sorts them according to the request IDs, since the customer with smaller request ID will receive his license earlier than the one with higher request ID. *When a customer arrives to receive his/her license, s/he is directed to the specialized employee(according to the brand of the car being licensed). S/he is also assigned a turn to receive his/her license according to the assigned request IDs. To simulate the described process, you are required to implement the following: Class LicensingOffice which keeps track of the employees in an array data structure. It is initialized by passing the number of employees working in the office. Provide the class with the following methods: * void addEmployee(String brand) that inserts a new employee into the array, after specifying the car brand that he serves as input to the method. * int LicenseApplication(String brand) that assigns the customer a request ID and passes his request to the correct employee to be processed (depending on the car brand). The method will return -1 in case that the brand is not served at the office or the employee serving the brand cannot accept more licenses for the day. * void processDayRequests()that orders the employees to start processing the requests they have. * int[]recieveLicense(String brand,int reqID)that returns an array of two items. The first item is the number of the employee who serves the brand (his index in the array of employees). The second one is the turn of the customer request at the employee. The method returns null if the customer request is not found as a processed request.  Class Employee with attributes representing the car brand that this employee serves, the requests that s/he has received but has not been processed yet and the processed requests, sorted according to the request ID. Each employee has a maximum number of 50 requests that s/he can process per day. Provide the class with the following methods:  void newRequest(int requestID) which takes as input the ID of a request and adds this ID to the unprocessed requests of the employee.  void processRequests() which handles all the unprocessed requests, by moving them to the data structure holding the processed requests.  int getTurn(int requestID) which takes as input the request ID and returns the turn of the customer with this ID, given the fact that those with smaller request IDs are served first.  Class Customer with attributes representing the car brand, request ID, the ID of the employee who will serve him and his turn to be served by this employee. Note that not all the attributes are known by the customer. Some of them will be assigned by the licensing office whenever s/he applies for the license. Provide the class with the following methods:  void applyForLicense() that simulates the user application for a license. This method should set the value of the attribute representing the request ID.  void recievalTiming() that simulates the receiving process by setting the values of the attributes representing the ID of the employee who will serve the customer and the customer's turn. Note that all customers will head to the same licensing office.  A main method to test the class by simulating a minioofice with 3 employees and 7 customers. The three employees serves the brands Mercedes,Opel and Volks Wagen. The seven customers submits their application in the following order Mercedes owner, Volks Wagen owner, Mercedes owner, Opel owner, Volks Wagen owner, Opel owner, Mercedes owner. Your main method should print the attributes of each customer after the receiving his/her license. You are only allowed to use arrays in the class Office. In the other classes, you can only use instances of StackObj, QueueObj and PriorityQ.

View Answers

November 1, 2010 at 6:52 PM

Sorry for not posting my problem,I couldn't understand how to link between Stacks and Queues in this problem and I also don't understand the concept of the priority of Queues I mean that the priority here is the car brand or another hey???


November 10, 2010 at 3:31 AM

where did u found this problem please ??


November 10, 2010 at 10:53 PM

why are you asking? anyway I want to be well practised so when I searched for online problems I found it posted so I just want to know its answer.


November 10, 2010 at 10:54 PM

so please can you explained to me ???


November 11, 2010 at 4:40 PM

i am trying to solve it but i fail everytime ... so i would like to know where you found it cause my Teacher assistant gave us this problem and told us to solve it and its toooo difficult :S :S and i am sure he copied it from some place .... if you can help me with where you found it maybe it will help me to solve it :S and i will send u the solution .... :S i spent a whole day trying to solve it but i still fail


November 11, 2010 at 4:55 PM

i will write to you an explanation as soon as possible today


November 11, 2010 at 8:03 PM

I found it on a site but I don't remember its name exactly :S pls try to help me because I have an exam on Saturday and I am sure that the exam will include a problem that will be similar to it


March 17, 2012 at 12:20 AM

where is answer ??









Related Tutorials/Questions & Answers:
I couldn't solve it
I couldn't solve it  *A customer who wants to apply for getting a car license should provide information about the brand of the car. *Then the customer receives a request ID from the office. *The customer's request (represented
Exception "Couldn't load database driver: com.mysql.jdbc.Driver". I
Exception "Couldn't load database driver: com.mysql.jdbc.Driver". I  I m trying to connect to mysql from netbeans 6.9 but i m getting this exception "Couldn't load database driver: com.mysql.jdbc.Driver". I ve added the connector
Advertisements
i dont no how to solve it pls
i dont no how to solve it pls   Calculate and display the sum of all prime number from 1 to 100 covert in java system codes
i need help to solve this problem
i need help to solve this problem  Write a stack class ArrayStack.java implements PureStack interface that reads in strings from standard input.... H and I join the queue h. G leaves the queue i. H and I leave the queue
how do i solve this problem?
how do i solve this problem?  Define a class named Circle with the following properties: List item An integer data field named radius with protected access modifier, and a String data field named colour with private access
how do i solve this question?
how do i solve this question?  1.Define a class named Circle with the following properties: a) An integer data field named radius with protected access modifier, and a String data field named colour with private access modifier
how should i can solve
how should i can solve  Web based program - Input - Person's contact details with Passport Number as Unique Key. Save data in to oracle / MySQL. Output - List of Persons saved in the database. Technology to be used - JSP
Solve it
Solve it  How to calculate the value which contains oparator and operand both using command line argument
solve this
solve this   Create a student class. The student object should have studentid, studentname, subject and marks as properties. Also generate the getter and setter methods. Create 5 objects of this class and populate values
please help me solve this problem when i am create database connection using servlecontext
please help me solve this problem when i am create database connection using servlecontext  hi... I have create a database connection using servletcontext . in this code when i login first time it will exceute sucessfully
solve this pbm
solve this pbm  sir rows are also inserting i have checked in the database also the rows are not affected in the table . The first pbm wich i have sent to you is not yet solved.......... pls give me detail explaination how we
solve this pbm
solve this pbm  its not working the code for databae access using servlets
how to solve
how to solve   log4j:WARN No appenders could be found for logger (org.apache.struts.util.PropertyMessageResources). log4j:WARN Please initialize the log4j system properly
solve this problem
solve this problem  I typed this program and compiled.The program is compiled but when i eneterd url in tomcat server. Its not giving error but only...)"; int i = statement.executeUpdate(query); if(i!=0
Solve
how to solve this..
how to solve this..  Given a list of students and their marks Name | Science | Math | English | Computer Ahmad | 28 | 100 | 66 | 34 Samad | 56 | 89 | 55
how to solve this..
how to solve this..  Given a list of students and their marks Name | Science | Math | English | Computer Ahmad | 28 | 100 | 66 | 34 Samad | 56 | 89 | 55
Solve Program - Java Beginners
Solve Program  Write a progaram in java to display all odd number...[]){ for(int i = 1; i<=100; i=i+2){ System.out.print(i...{ public static void main(String[] args){ try{ for(int i = 1; i<=100
to solve the error - Java Beginners
to solve the error  class bubbleSort1{ public static void...++) { // count how many times // This next loop becomes shorter and shorter for (int i=0; i < n-pass; i++) { if (x[i] > x[i+1]) { // exchange elements int temp
how to solve an internet connection problem
how to solve an internet connection problem  when i run my application it give me this error: Exception in thread "AWT-EventQueue-0" java.lang.UnsupportedOperationException: Not yet implemented the problem is that i don`t know
ModuleNotFoundError: No module named 'solve'
ModuleNotFoundError: No module named 'solve'  Hi, My Python program is throwing following error: ModuleNotFoundError: No module named 'solve' How to remove the ModuleNotFoundError: No module named 'solve'
plz solve my query?
plz solve my query?  how to remove all the options from select control in html using java script?   JavaScript remove all items <...) { var i; for(i=selectbox.options.length-1;i>=0;i--) { selectbox.remove(i
solve it - Java Beginners
solve it  Hi friend, I want to use switch case in jsp please let me know how to call page in jsp using include tag i want call this file...")!=""){ for(int i=0; i<request.getParameter("num").length(); i++){ char value
can interface solve this problem in java
can interface solve this problem in java  I have a JDialog which displays the calendar [from 2010-2020], i created this in a different class.... Now i need to get which day is clicked by the user from another class which calls
Solve it - Java Beginners
Solve it  Hi Friends, Thanks for continue reply.. I have some query please solved...its urgent.. I have two table,emp,exam.both have e... is completed,but i want this information display in trainee section i want login type
A Program To Solve In Java
A Program To Solve In Java  x!/x+(x+2)!/x+(x+4)!/x ... (x+n)!/x
Solve this problem plzzz
Solve this problem plzzz  Prashant.jsp (this is my JSP file) <... Prashant /Prashant.jsp i want my jsp file should ask for 2 inputs (2 text boxes) and 1 button(submit button) when i put 2 numerica value
ArrayList question plz solve it
ArrayList question plz solve it  An arraylist object stores an Emp Object, where there is name,age,address of the employee is stored, And i want...","Mathura",25)); list.add(new EmployeeData("I","Delhi",23)); list.add
Please Help To Solve My Problem
Please Help To Solve My Problem  PHP I Have 6 Textbox and 1 ok... With B Team when A Team Play With B Team Again Then Generate Error. I Am Solve...) When I Add This Six Team Name In Six Text Box Then I Will Click On Ok Button
solve my question shortly
solve my question shortly  <html> <head> <script>.... I have corrected your errors now you can run your code easily. I have also made changes in the calling of your method i.e. in place of textbox event I have
help me to solve this question
help me to solve this question  Write a program that inputs a series of integers into an array. The numbers are in the range 0 to 100. Calculate and display : a) The Largest number b) The Smallest Number c)The sum of the numbers
How to solve the Hibernate Common Exceptions?
How to solve the Hibernate Common Exceptions?  How to solve the Hibernate Common Exceptions
please solve this program
please solve this program  Build a package EMPPACK that contains one stored function Validatesal() and two stored procedures Insertemp() and Getempdetails().The Insert_emp() procedure inserts a particular employee
please solve the programme
please solve the programme  Develop a java program to find the roots of a quadratic equation ax2+bx+c=0, with the following specification :- Class name :- Quad Data members float a,b,c,d, with a,b,c are the co-efficient
need to solve the below question - Java Beginners
need to solve the below question  I need to write an application that uses the circle class.it must read a radius of a circle from the user .create a circle object and return the object
help me to solve this question...
help me to solve this question...  Given below is a class definition for Book. Type and compile the class, and answer the following questions: class Book { String title; //bookâ??s title double price; //bookâ??s
help me to solve this problem..
help me to solve this problem..  Given below is a class definition for Book. Type and compile the class, and answer the following questions: class Book { String title; //bookâ??s title double price; //bookâ??s price
How to Solve the Syntax Error in java??
How to Solve the Syntax Error in java??  Syntax error in java? i have... on token "i", VariableDeclarator expected after this token" . in last line... "i" import java.util.Scanner; public class constructors { int i ; private int
ModuleNotFoundError: No module named 'flood-solve'
ModuleNotFoundError: No module named 'flood-solve'  Hi, My Python... 'flood-solve' How to remove the ModuleNotFoundError: No module named 'flood-solve' error? Thanks   Hi, In your python environment
ModuleNotFoundError: No module named 'magiceye_solve'
ModuleNotFoundError: No module named 'magiceye_solve'  Hi, My... named 'magiceye_solve' How to remove the ModuleNotFoundError: No module named 'magiceye_solve' error? Thanks   Hi, In your python
ModuleNotFoundError: No module named 'solve-instrument'
ModuleNotFoundError: No module named 'solve-instrument'  Hi, My... named 'solve-instrument' How to remove the ModuleNotFoundError: No module named 'solve-instrument' error? Thanks   Hi, In your
ModuleNotFoundError: No module named 'sudoku-solve'
ModuleNotFoundError: No module named 'sudoku-solve'  Hi, My Python... 'sudoku-solve' How to remove the ModuleNotFoundError: No module named 'sudoku-solve' error? Thanks   Hi, In your python
ModuleNotFoundError: No module named 'sudoku-solve'
ModuleNotFoundError: No module named 'sudoku-solve'  Hi, My Python... 'sudoku-solve' How to remove the ModuleNotFoundError: No module named 'sudoku-solve' error? Thanks   Hi, In your python
ModuleNotFoundError: No module named 'flood-solve'
ModuleNotFoundError: No module named 'flood-solve'  Hi, My Python... 'flood-solve' How to remove the ModuleNotFoundError: No module named 'flood-solve' error? Thanks   Hi, In your python environment
Check Digit Question not able to solve..
Check Digit Question not able to solve..   Hi, I need some help asap. I been stuck for this question for more than 3 days. Using Java. User needs to key in identification number (e.g. U0906931E) system check for the first
Solve my code
Solve my code  import javax.servlet.*; import javax.servlet.http.*; import java.sql.*; import java.io.*; public class ChangeDetails extends HttpServlet{ public void doPost(HttpServletRequest request,HttpServletResponse
help me to solve this question
help me to solve this question   A user needs to key in data into system in order to save data into array. The data are: a. Lecturer ID, Lecturer name, School, course code, course name, session, semester A user can edit the data
plz help meto solve this question
plz help meto solve this question  for a file that exist what will be the length() method in the file class return
how to solve 'Stop Running This Script' Error ?
how to solve 'Stop Running This Script' Error ?  Hi.. When opened the page on IE browser(version : 8.0),it gives an java script error (i.e.Stop Running This Script). I have used jsp/servlet for this. Please help to resolved
Solve using only Javascript loops...
Solve using only Javascript loops...  Write a JavaScript code, 1... totalCount; var count=0; for(var i = 0; i < str.length; i++){ if(!array[str[i]]) { array[str[i]] = 1; } else { array

Ads