Interesting Quizzes!-JavaScript dated 21/03/2023

Hello Everyone!
Today i have attached few questions here!
Please reply your answer!

  1. Which of the following is not a built-in JavaScript data type?
    A) Boolean B) String C) List D) Number

  2. Which data structure uses LIFO (Last-In-First-Out) ordering?
    A) Queue B) Stack C) Hash table D) Linked list

  3. Which sorting algorithm has a worst-case time complexity of O(n^2)?
    A) Quick sort B) Merge sort C) Bubble sort D) Insertion sort

  4. Which of the following is a common use case for a hash table?
    A) Maintaining a sorted list of elements B) Storing key-value pairs for fast retrieval C) Sorting a list of elements D) Implementing LIFO ordering

  5. Which data structure represents a collection of elements in a linear sequence?
    A) Queue B) Stack C) Hash table D) Linked list

Have a Happy Learning
Thanks & Regards
Teaching Assistant,
Dharshini M.

1 Like

------------------------>>>>>Answers<<<<<---------------------(Python)

1 (c)
2 (A)
3 (C)
4 (B)
5 (D) and If we implement Stack or Queue using Array. so as per my knowledge Array represent a collection of element in a liner sequence so Stack & Queue also correct option.

*Thanks & Regards *
Ansh Srivastav

1 Like

@sriv.ansh Thank you for your valuable response!

1.list
2.stack
3.
4.
5.linked list or stack