100% satisfaction guarantee Immediately available after payment Both online and in PDF No strings attached
logo-home
WGU C949 Data Types STUDY GUIDE Questions and Answers Fully Solved $13.99   Add to cart

Exam (elaborations)

WGU C949 Data Types STUDY GUIDE Questions and Answers Fully Solved

 3 views  0 purchase
  • Course
  • WGU C949
  • Institution
  • WGU C949

WGU C949 Data Types STUDY GUIDE

Preview 2 out of 7  pages

  • August 10, 2024
  • 7
  • 2024/2025
  • Exam (elaborations)
  • Questions & answers
  • WGU C949
  • WGU C949
avatar-seller
Dreamer252
WGU C949 Data Types STUDY GUIDE

Array - answerA data structure that stores an ordered list of items, with each item is
directly accessible by a positional index.

Linked List - answerA data structure that stores ordered list of items in nodes, where
each node stores data and has a pointer to the next node.

Bianary Search Tree - answerA data structure in which each node stores data and has
up to two children, known as a left child and a right child.

Hash Table - answerA data structure that stores unordered items by mapping (or
hashing) each item to a location in an array (or vector).

Abstract Data Type (ADT) - answerA data type described by predefined user
operations, such as "insert data at rear," without indicating how each operation is
implemented.

List - answerAn ADT for holding ordered data. Dups ok

Sequence type: A mutable container with ordered elements.

Underlying data structures: Array, linked list

Array in Java - answergeneric class that supports different data types. declared as
follows, where T is the data type.

Tuple - answerSequence type: An immutable container with ordered elements.

Stack - answerAn ADT in which items are only inserted on or removed from the top of a
stack.
*Last-in First-Out

Underlying data structures: Linked list

Push(stack, x), pop(stack), peek(stack), IsEmpty(stack), GetLength(stack)

*Pop & peek should not be used on a empty stack.

Stack operations - answerExample starting with stack: 99, 77 (top is 99).

Push(stack, x)

, Inserts x on top of stack
Push(stack, 44). Stack: 44, 99, 77

Pop(stack)
Returns and removes item at top of stack
Pop(stack) returns: 99. Stack: 77

Peek(stack)
Returns but does not remove item at top of stack
Peek(stack) returns 99. Stack still: 99, 77

IsEmpty(stack)
Returns true if stack has no items
IsEmpty(stack) returns false.

GetLength(stack)
Returns the number of items in the stack
GetLength(stack) returns 2.

Queue - answerAn ADT in which items are inserted at the end of the queue and
removed from the front of the queue.

*first-in first-out ADT.

Underlying data structures: Linked list, Array, Vector

The Queue class' push() method uses the LinkedList append() method to insert
elements in a queue.

Both the Stack and Queue pop() methods operate exactly the same by removing the
head element and returning the removed element.

Linked List - answerA linear data structure, much like an array, that consists of nodes,
where each node contains data as well as a link to the next node, but that does not use
contiguous memory.
Head and tail node

The LinkedList class implements the list data structure and contains two data members,
head and tail, which are assigned to nodes once the list is populated. Initially the list has
no nodes, so both data members are initially assigned with None.

If the node has no next node, the next data member is assigned with None, the Python
term signifying the absence of a value.

Deque - answerShort for double-ended queue- an ADT in which items can be inserted
and removed at both the front and back.

The benefits of buying summaries with Stuvia:

Guaranteed quality through customer reviews

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

Quick and easy check-out

You can quickly pay through credit card or Stuvia-credit for the summaries. There is no membership needed.

Focus on what matters

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 Dreamer252. Stuvia facilitates payment to the seller.

Will I be stuck with a subscription?

No, you only buy these notes for $13.99. You're not tied to anything after your purchase.

Can Stuvia be trusted?

4.6 stars on Google & Trustpilot (+1000 reviews)

73773 documents were sold in the last 30 days

Founded in 2010, the go-to place to buy study notes for 14 years now

Start selling
$13.99
  • (0)
  Add to cart