An object that groups other objects and provides services to

An object that groups other objects and provides services to its clients is called a/an:

Flag this Question Question 22 2 pts An object of type Node that contains a data type of Node is a

Flag this Question Question 23 2 pts Where is a new node added to a linked list?

Flag this Question Question 24 2 pts An algorithm has

Flag this Question Question 25 2 pts

1.      A measure of an algorithm\'s execution needs is called

Flag this Question Question 26 2 pts An implementation of an ADT with a programming language is called a/an:

Flag this Question Question 27 2 pts What happened when a bag becomes full in a linked list implementation?

Flag this Question Question 28 2 pts

1.       A stub is created for what purpose?

Flag this Question Question 29 2 pts

1.       When implementing the bag ADT, which scenario could result in a security problem?

Flag this Question Question 30 2 pts A stub should ______________.

Flag this Question Question 31 2 pts Which method removes all entries of a bag?

Flag this Question Question 32 2 pts

1.     Which one of the following Java statements allocates an array in the bag constructor causing a compiler warning for an

unchecked operation? Assume capacity is an integer.

Flag this Question Question 33 2 pts

1.      Which code correctly adds the first entry to an empty bag?

Flag this Question Question 34 2 pts Which of the following methods is a good candidate for a core method?

Flag this Question Question 35 2 pts Accessing all of the nodes in a chain beginning with the first one is called a(n)

Flag this Question Question 36 2 pts

1.      For large values of n which statement is true?

Flag this Question Question 37 2 pts Which of the following methods is a good candidate for a core method?

Flag this Question Question 38 2 pts A language-dependent specification for a group of values and operations on those values is called a/an:

Flag this Question Question 39 2 pts Which method removes one occurrence of a particular entry from a big if possible?

Flag this Question Question 40 2 pts

1.       When implementing the bag ADT, which scenario could result in a security problem?

Flag this Question Question 41 2 pts Problem size is defined as

Flag this Question Question 42 2 pts

1.      When you write a program for an algorithm and it is taking much longer than expected you should

Flag this Question Question 43 2 pts Which method returns a count of the current number of items in a bag?

Flag this Question Question 44 2 pts

1.      To measure the time requirement of an algorithm, we must

Flag this Question Question 45 2 pts

1.      To properly evaluate the effectiveness of an algorithm, you need to determine

Flag this Question Question 46 2 pts

1.      Computing the sum of the first n integers using the formulat n * (n + 1) / 2 has a growth rate

Flag this Question Question 47 2 pts

1.       Which instruction suppresses an unchecked-cast warning from the compiler?

Flag this Question Question 48 2 pts Which method removes one unspecified entry from a bag if possible?

Flag this Question Question 49 2 pts When removing a node from a chain, what case should we consider?

Flag this Question Question 50 2 pts Why would the add method return false?

collection

Solution

21. An object that groups other objects and provides services to its clients is called a/an:
data structure.

22. An object of type Node that contains a data type of Node is a
forward reference. A forward reference is the part of a Node which refers to another Node.

23. Where is a new node added to a linked list?
in a random place. The advantage of the linked list is that, nodes can be inserted at
any place, just using/reconnecting the links.

24. An algorithm has
both a and b. An algorithm is the flow of steps to achieve a particular task. But when
giving a flow, the requirements is that, it should use some limited space, and should
terminate for sure. Therefore, an algorithm has both time and space requirements.

25. A measure of an algorithm\'s execution needs is called
time complexity. The algorithm efficiency measure is usually done using the time complexity.

26. An implementation of an ADT with a programming language is called a/an:
abstract data type. The name ADT itself is an Abstract Data Type.

27. What happened when a bag becomes full in a linked list implementation?
This condition is not possible with a linked list implementation. Theoretically speaking
linked list gets another node from the computers memory, and will make use of it. And this
will continue as much as required by the program. But in practical, the possibility is that,
the computer itself may run out of memory, and therefore, requesting much further could lead
to hardware failure, which could lead to An OutofMemoryError will occur.

28. A stub is created for what purpose?
to practice fail-safe programming. Usually a stub is used to test the code as a whole,
especially when the code has not been completely developed.

29. When implementing the bag ADT, which scenario could result in a security problem?
a group of core methods is not defined

30. A stub should ______________.
all of the above . As early discussed, stub itself is to use a dummy block to test the
other part of the code more seriously, and as a whole. Therefore, if this part is invoked,
it should report/display a message, and should return a dummy value, and ofcourse is
written early for testing purpose.

An object that groups other objects and provides services to its clients is called a/an: Flag this Question Question 22 2 pts An object of type Node that contai
An object that groups other objects and provides services to its clients is called a/an: Flag this Question Question 22 2 pts An object of type Node that contai
An object that groups other objects and provides services to its clients is called a/an: Flag this Question Question 22 2 pts An object of type Node that contai

Get Help Now

Submit a Take Down Notice

Tutor
Tutor: Dr Jack
Most rated tutor on our site