CSE445 MODULE 2 EXAM QUESTIONS AND ANSWERS WITH COMPLETE SOLUTIONS VERIFIED LATEST UPDATE
3 views 0 purchase
Module
CSE 445
Institution
CSE 445
CSE445 MODULE 2 EXAM QUESTIONS AND ANSWERS WITH COMPLETE SOLUTIONS VERIFIED LATEST UPDATE
In what situations can a deadlock occur? Select all that apply
- There are two shared resources.
- There are more than two shared resources.
- There is no shared resource.
- There is one shared resour...
cse445 module 2 exam questions and answers with co
Written for
CSE 445
All documents for this subject (44)
Seller
Follow
NurseAdvocate
Reviews received
Content preview
CSE445 MODULE 2 EXAM QUESTIONS AND
ANSWERS WITH COMPLETE SOLUTIONS VERIFIED
LATEST UPDATE
In what situations can a deadlock occur? Select all that apply
- There are two shared resources.
- There are more than two shared resources.
- There is no shared resource.
- There is one shared resource.
- There are two shared resources
-
Ethernet's binary exponential backoff mechanism is a technique used for
avoiding
livelock
A thread
exists when the corresponding code is running
Compare and contrast livelock and deadlock. What statement is correct?
In the case of deadlock, the resources are held. In the case of livelock, the resources
are still free.
, What technique can be used to make sure that parallel withdrawals from ATMs
cannot exceed the given limit of a bank account?
Implement a lock mechanism to prevent simultaneous access to the account object.
What is the proper way of creating a thread class if the class has already
inherited members from another class?
Implement the Runnable Interface
Which method is the starting point in a user-defined Java thread class?
run
Compare and contrast wait( ) and sleep(t) methods defined in the library class
Thread.
A thread in the wait state cannot return to the ready state unless another thread issues
a notification.
How is the synchronization mechanism implemented in a Java environment?
A lock-bit in an object is set to "true" when a synchronized method accesses the object.
If a method is prefixed with the keyword "synchronized", then
all objects accessed by the method will be locked during the execution of the method.
Can Monitor.Enter(v) lock the variable v if v is of integer type?
No, Monitor.Enter(v) cannot directly lock the variables of value-type.
Which method is the starting point in a user-defined C# thread class?
a user-named method
The C# monitor class's methods Monitor.Enter and Monitor.Exit can be used for
synchronizing a set of statements, similar to the synchronized statements in Java.
The benefits of buying summaries with Stuvia:
Guaranteed quality through customer reviews
Stuvia customers have reviewed more than 700,000 summaries. This how you know that you are buying the best documents.
Quick and easy check-out
You can quickly pay through credit card for the summaries. There is no membership needed.
Focus on what matters
Your fellow students write the study notes themselves, which is why the documents are always reliable and up-to-date. This ensures you quickly get to the core!
Frequently asked questions
What do I get when I buy this document?
You get a PDF, available immediately after your purchase. The purchased document is accessible anytime, anywhere and indefinitely through your profile.
Satisfaction guarantee: how does it work?
Our satisfaction guarantee ensures that you always find a study document that suits you well. You fill out a form, and our customer service team takes care of the rest.
Who am I buying these notes from?
Stuvia is a marketplace, so you are not buying this document from us, but from seller NurseAdvocate. Stuvia facilitates payment to the seller.
Will I be stuck with a subscription?
No, you only buy these notes for £8.16. You're not tied to anything after your purchase.