0% found this document useful (0 votes)
5 views7 pages

PCCCS301_Module1-1

Analog electronics

Uploaded by

trithrai
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views7 pages

PCCCS301_Module1-1

Analog electronics

Uploaded by

trithrai
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 7

Questions from Module 1 of Study Material

Sl. Bloom's
Question CO Hints
No. level
Contrast between using a linear data
structure (e.g., array) and a non-linear data
Compare and contrast the advantages
structure (e.g., tree) depends on the specific
and disadvantages of using a linear data
requirements of the application. If the
1 structure (e.g., array) versus a non-linear CO3 4
dataset has a fixed size and frequently
data structure (e.g., tree) in terms of
requires random access, an array might be
memory usage and search efficiency.
a better choice due to its memory
efficiency and constant-time access.
Analyze the time complexity of different
data structures (e.g., arrays, linked lists, Start by recalling the meaning of time
2 stacks) and evaluate their efficiency for CO3 4 complexity. Consider various fundamental
various operations such as insertion, operations with linear data structures.
deletion, and retrieval.
An array-based stack offers better memory
Compare and contrast the advantages efficiency and random access, but it is
and limitations of different techniques limited by its fixed size and the need for
for implementing a stack (e.g., array resizing. On the other hand, a linked list-
3 based stack, linked list-based stack), CO3 5 based stack can handle variable-sized data
considering factors such as memory more efficiently without the overhead of
efficiency and the ability to handle resizing, but it sacrifices random access
variable-sized data. and has slightly higher memory overhead
due to pointers.
Develop a data structure that maintains a
running sum of a stream of numbers, Strat by recalling the concept of the
4 allowing constant-time queries for the CO4 6 modified version of Binary Tree which is
sum of a given range of elements, and known as Binary Indexed Tree.
analyze its time complexity.
Start by recalling what notations we use to
compare orders of growth. Elaborate on
Justify the significance of asymptotic
5 CO3 5 each of them. Remember to explain the
notation in algorithm analysis
concepts of both upper and lower bounds
with respect to the asymptotic function.
Start by recalling the meaning of time and
Justify the statement: ‘A trade-off has to
space complexity. Consider the
6 be maintained between time and space CO3 5
implications of each. Finally, highlight how
complexity’.
the balance required between both.
Design and write an algorithm having All the steps of the algorithm must be very
7 CO4 6
worst case time complexity as O(log n). simple, clear and basic.
Appraise the complexity of an algorithm Estimate the number of steps of the
8 which performs a task of calculating a CO3 5 problem and the frequency of execution of
sum of 'n' numbers. each.
Bob wants to search an element 42 from
a given array
You have to find the mid value using start
{12, 13,14,32,21,42,54} but his
and end index of the array. If search
computer is not having
9 C04 6 element is mid then return the value,
capabilities to handle time complex data
otherwise you have to change the start
in order of
value or end value.
n^2. Suggest Bob a way so that he can
find the
element using binary search. Also
determine the
overall time complexity.
Searching in a phone book: A phone
book is stored in
a text file, containing names of people,
their city names
10 and phone numbers. Choose an CO3 4 Try Quick sort for this purpose.
appropriate data
structure to search a person’s phone
number based on
his / her first name and city.
T(n) =2T(n/2) +O(n)
Learn about the time complexity then solve
11 Determine the time complexity using CO3 5
the question.
taking O(n) = n.
User enter the array element:
10,20,30,30,10,9,40
solve the given problems by creating Duplicate elements can be found using two
suitable loops. The outer loop will iterate through
algorithm: the array from 0 to length of the array. The
12 (a)How do you find duplicate numbers CO4 4 outer loop will select an element. The inner
in an array if it loop will be used to compare the selected
contains multiple duplicates? element with the rest of the elements of the
array.
(b) How to remove duplicates from a
given array?
Using the abstract data type "Stack,"
design a program to evaluate a simple
1. Explain the concept of postfix notation
arithmetic expression in postfix notation.
and its relationship with stacks. 2. Design
Implement the necessary methods to
the required methods for the stack to
13 push operands onto the stack and CO4 4
handle operands and operators efficiently.
perform calculations using operators.
3. Provide a step-by-step example of how
The expression consists of integers and
the stack evaluates a postfix expression.
four basic arithmetic operators (+, -, *,
/).
You are given a string containing
parentheses (e.g., "((()))()()"). Design a 1. Design the necessary methods for the
program using the stack data structure to stack to process the given string efficiently.
14 determine if the parentheses in the string CO5 5 2. Provide a step-by-step example of how
are balanced. The program should return the stack checks the balance of parentheses
"True" if the parentheses are balanced in a sample string.
and "False" otherwise.
Suppose, the manager of a call centre
wants to optimize the way customer
1. Explain the concept of a Queue data
inquiries are handled by your team.
structure and its analogy with a real-life
Design a program using the Queue data
queue. 2. Design the required methods for
structure to simulate a call queue
15 CO4 4 the queue to manage calls effectively. 3.
system. Implement the necessary
Provide a step-by-step example of how the
methods to add incoming calls to the
queue operates as visitors join and leave
queue, process them one by one as the
the ride.
agents become available, and display the
current queue status.
Imagine you are in charge of organizing
a small amusement park. You want to
manage the ride queues efficiently to 1. Explain the concept of a Queue data
ensure a smooth experience for visitors. structure and its analogy with a real-life
Design a program using the Queue data queue. 2. Design the required methods for
16 structure to simulate the queueing CO5 5 the queue to manage visitors effectively. 3.
system for one of the popular rides. Provide a step-by-step example of how the
Implement the necessary methods to add queue operates as visitors join and leave
visitors to the queue, remove them after the ride.
they have enjoyed the ride, and display
the current queue status.

You might also like