Questions
Consider the TA assignment problem where n Teaching Assistants (TAs) are to be assigned to n...

Consider the TA assignment problem where n Teaching Assistants
(TAs) are to be assigned to n courses with one course having exactly
one TA. Each course ranks all of the TAs, and each TA ranks all the
courses, from most to least desirable.
Can you provide an example of an assignment and preference lists such
that every TA and course forms an unstable pair? (Yes/No). If Yes,
present the assignment. If No, justify your answer.
note: gale shapley algorithm

In: Computer Science

Consider the following set of processes, with the length of the CPU-burst time given in milliseconds,...

Consider the following set of processes, with the length of the CPU-burst time given in milliseconds, and the priority given in integers (lower numbers represent higher priorities) :

    Process Arrival Time Burst Time priority   

      P1                             0 17 2

      P2 5 8 3

      P3 7 11 1

a. Draw Gantt charts illustrating the execution of these processes using nonpreemptive priority and preemptive priority, and Round Robins scheduling (time quantum = 4 ms).

b. What is the turnaround time of each process for each of the scheduling algorithms in part a?

In: Computer Science

java.applet java.awt java.awt.event java.swimg.JOptionPane Make a JAVA program decisional structure, message box, matching box, number format....

java.applet
java.awt
java.awt.event
java.swimg.JOptionPane



Make a JAVA program decisional structure, message box, matching box, number format.
Entry of Data:
Customer Name
Customer Number
Discount: New Customer 10% Existing Customer 5%
Registration: Daily $5 Weekly $20 Monthly $40 Annual $80
Calculate in a function the cost of registration according to the discount and type of registration
You must display the cost and a message box showing the selected alternatives; the result boxes must be visible when the button is pressed and cannot be altered. You must contemplate the different errors, use " try and catch". Create color and apply to the form.
Add button to clear text boxes and variables.

In: Computer Science

SHOW WORK Sort the given keys using Counting sort algorithm. Also write the algorithm.          5, 2,...

SHOW WORK

Sort the given keys using Counting sort algorithm. Also write the algorithm.

         5, 2, 3, 1, 0, 2, 1, 5, 0                                                                 

SHOW WORK!

In: Computer Science

BOVOU PWN <?php echo Hello World!; 77

BOVOU PWN <?php echo Hello World!; 77

In: Computer Science

(Java Programming Problem) Build two ArrayList lists from the Integer and String type arrays, populate the...

(Java Programming Problem)

Build two ArrayList lists from the Integer and String type arrays, populate the lists with repeats (see example below). Write a generic method (removeDuplicates( ….. )) to remove those duplicate items and returns an ArrayList<E> list without duplicates.

Original Integer List: [14, 24, 14, 42, 24, 25, 25, 23]

No-Duplicate List: [14, 24, 42, 25, 23]

Same generic method for the name list

Original List: [Mike, Lara, Jenny, Lara, Jared, Jonny, Lindsey, Mike, Jared]

No-Duplicate List: [Mike, Lara, Jenny, Jared, Jonny, Lindsey]

In: Computer Science

1. Write CREAT TABLE statements for the following tables (primary keys are underlined, foreign keys are...

1. Write CREAT TABLE statements for the following tables (primary keys are underlined, foreign keys are in italic and bold). Make sure you have all needed constraints and appropriate datatypes for attributes:

Student (stID, stName, dateOfBirth, advID, majorName, GPA)

Advisor (advID, advName, specialty)

2.  Insert several records in each table.

In: Computer Science

In Java, I need a program that will ask a user to input how many tests...

In Java, I need a program that will ask a user to input how many tests they want the average of. For example, It needs to ask the user how many tests would you like the average of? When the user enters the amount of tests they want the average score of, the program needs to give them that many test scores to input. Then with the average, determine what their grade is, if 90-100=A if 80-90 = B etc. Java and please explain.

In: Computer Science

Use C++ The ADT UnsortedType List function ‘DeleteItem(ItemType item)’ creates an endless loop error when trying...

Use C++

The ADT UnsortedType List function ‘DeleteItem(ItemType item)’ creates an endless loop error when trying to delete a word or key that is not in the list.

Example: Delete the word “letter” from the unsorted list.

Here are the lists contents before the DeleteItem(ItemType item) call:

super     formula travel     free        thick      Josephine            Clara      education

The question is ‘how can I exit gracefully from the DeleteItem(itemType Item) call when the word or key is not in the unsorted list and not get an endless loop but instead printing out a message that the word ‘letter’ is not in the loop? What code can be added?

void UnsortedType::DeleteItem(ItemType item)

{

NodeType* location;

NodeType* tempLocation;

location = listData;

if (item.ComparedTo(location->info) == EQUAL)

{

    tempLocation = location;

    listData = listData->next;

}

else

{

    while (!((item.ComparedTo((location->next)->info) == EQUAL)))

      location = location->next;

    tempLocation = location->next;

    location->next = (location->next)->next;

}

delete tempLocation;

length--;

}

In: Computer Science

Suppose A and B are regular language. Prove that AB is regular

Suppose A and B are regular language. Prove that AB is regular

In: Computer Science

1. Write CREAT TABLE statements for the following tables (primary keys are underlined, foreign keys are...

1. Write CREAT TABLE statements for the following tables (primary keys are underlined, foreign keys are in italic and bold). Make sure you have all needed constraints and appropriate datatypes for attributes: Student (stID, stName, dateOfBirth, advID, majorName, GPA) Advisor (advID, advName, specialty) 2. Insert several records in each table.

In: Computer Science

Convert the decimal floating point value 8.125 to a 12 bit binary floating point value. Use...

Convert the decimal floating point value 8.125 to a 12 bit binary floating point value. Use a sign bit, 3 bits (excess 3) for the exponent and an 8 bit significand. Enter just a 12 digit binary value ( e.g. 0 000 11110000 ) spaces ignored.

In: Computer Science

Discuss how companies use social media information to identify trends for products. Provide an example of...

Discuss how companies use social media information to identify trends for products. Provide an example of a software or analytics tool that is used to gather data. What legal or ethical issues does this type of information gathering present? Provide two examples and justify your ideas with specific reasons, facts, and examples.

In: Computer Science

x = 1:0.5:10 and a = 7.5, what does the following code do? (x > a)...

x = 1:0.5:10 and a = 7.5, what does the following code do?
(x > a) .* (x-5).^2
Explain it qualitatively and then provide the solution.

In: Computer Science

1. True or False? If one programmer in a large team is given the task of...

1. True or False? If one programmer in a large team is given the task of writing a single function for the team project, this programmer is more likely to need a function driver than a function stub.

2. A(n) ____________________ is a dummy function that is included for testing the higher-level code.

3. ____________________ is the principle that a module should perform exactly one abstract action.

4.

For the function definition
int SomeFunc( /* in */ int alpha,
/* in */ int beta )
{
int gamma;
alpha = alpha + beta;
gamma = 2 * alpha;
return gamma;
}
what is the function postcondition?

a. // Postcondition: gamma == 2*alpha

b. // Postcondition: alpha == alpha@entry + beta
// && gamma == 2*alpha

c. // Postcondition: Function value == gamma

d. // Postcondition: Function value == 2*alpha

e. // Postcondition: Function value == 2*(alpha@entry + beta)

5. ____________________ is a measure of the quantity of information passing through a module's interface.

6. In contrast to promotion, ____________________ of data values can potentially cause loss of information.

7.

Using the library functions available through the header file cctype, which of the following can be used to determine if the variable someChar contains either a digit character or a lowercase letter?

a. if (isalnum(someChar) || isdigit(someChar))

b. if (isalpha(someChar) || isdigit(someChar))

c. if (isalnum(someChar) && !isupper(someChar))

d. if (islower(someChar) || isdigit(someChar))

e. c and d above

8. True or False? For team programming to succeed, it is essential that all of the module interfaces be defined explicitly and the coded modules adhere strictly to the specifications for those interfaces.

9.

Which of the following could cause an unexpected side effect?

a. modifying a global variable

b. changing the value of a value parameter

c. referencing a global constant

d. declaring an incoming-only parameter to be a reference parameter

e. a and d above

10. True or False? Unsigned types are most appropriate for advanced techniques that manipulate individual bits within memory within memory cells to avoid errors caused by, for example, using unsigned variables for ordinary numeric computations.

In: Computer Science