0% found this document useful (0 votes)
24 views8 pages

Data Structures and Algorithms Overview

The document contains tutorials for algorithms and data structures, computer architecture, software architecture and design, and C# programming labs. The tutorials cover topics such as data structures, searching and sorting algorithms, queues, binary search trees, registers, Boolean logic, software development methodologies, and basic C# programs.

Uploaded by

sithumsankajith
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)
24 views8 pages

Data Structures and Algorithms Overview

The document contains tutorials for algorithms and data structures, computer architecture, software architecture and design, and C# programming labs. The tutorials cover topics such as data structures, searching and sorting algorithms, queues, binary search trees, registers, Boolean logic, software development methodologies, and basic C# programs.

Uploaded by

sithumsankajith
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

ALGO Tutorial 01.

1. Write down the difference between an array and structure.


2. Where should you use data structures.
3. What are the types of data structures.
4. What is a linked list data structure.
5. Compare and contrast linear data structures vs nonlinear data structures.

ALGO Tutorial 03.


1. Using an appropriate example, explain how main searching algorithms can be
performed.
2. Compare (look for similarities) and contrast (look for differences) linear search and
algorithms.
3. Write a function using pseudo or source codes for searching an integer variable called an
item using linear search in an array called an unordered array.
4. Write the C program for Binary search.
5. Briefly explain bubble sort, selection sort, and insertion sort.

ALGO Tutorial 04.


1. What is circular queue.
2. What are the characteristics of circular queue.
3. Give applications of circular queue.
4. What is algorithm of circular queue.
5. Write a simple program of circular.
6. Compare and contrast linear queue and circular queue.

ALGO Tutorial 05.


1. What is Binary Search.
2. What are the advantages and disadvantages of Binary Search.
3. Write the Algorithm of Binary Search.
4. Write a simple C program for Binary Search.

ALGO Tutorial 06.


Sorting Algorithms.
1. Explain how main sorting algorithms can be performed using an appropriate array
example.
2. Compare and contrast bubble sort and selection sort algorithms.
3. What are the real-world examples of sorting.
4. Write function using pseudo or source codes to sort an integer array using bubble sort
and selection sort.

ALGO Tutorial 07.


Consider a social media platform with millions of users and a vast amount of content, including
posts, photos, videos, and user profiles. Users often search for specific topics, hashtags or user
profiles within the platform to discover relevant content or connect with specific individuals.
Explain the application of searching and sorting algorithms in social media. Describe how the
techniques are used.

CA Tutorial 01.
A bulb in a staircase has two switches, one switch being at the ground floor and the other one
at the first floor. The bulb can be turned ON and can be turned off by and one of the switches
irrespective of the other switch.
a) Draw the truth table for above situation.
b) Draw the most suitable logic circuit / gate for this.

The Boolean function Y=AB+CD is to be realize using only 2 input NAND gates.
a) Extract the Boolean function for NAND gates using the above formula.
b) Draw the logic circuit for the extracted Boolean function.
CA Tutorial 03.
1) What is the primary purpose of registers in a CPU?
a) To store and manipulate data during instruction execution.
b) To control various aspects of the CPU’s operation.
c) To more data efficiently between memory and the ALU.
d) To hold memory addresses and function parameters.
2) Which type of registers is used to store flogs indicating the outcome of previous
operations?
a) General-purpose registers.
b) Program counters.
c) Stack painters.
d) Status registers.

3) What is the typical range of sizes for registers in a computer system?


a) 1 to 8 bits.
b) 8 to 16 bits.
c) 32 to 64 bits.
d) 64 to 128 bits.

4) How do registers contribute to the performance of a computer system?


a) By minimizing the impact of memory latency.
b) By controlling the CPU’s operation.
c) By storing intermediate results during arithmetic operations.
d) By moving data efficiently between the CPU and external devices.

5) Which component of the CPU contains registers?


a) Memory.
b) Cache.
c) Arithmetic logic unit (ALU).
d) Input / Output devices.

6) What is the purpose of general-purpose registers in computer architecture, and how are
they typically used?
7) How does the program counter register contribute to the execution of a program in a
CPU?
8) What role does the status registers (FLAGS) play in the CPU, and what types of
information does it typically contain?
9) Why are registers considered the fastest form of memory in a computer, and how does
their speed impact overall system performance?

CA Tutorial 04.
1. A circuit has a resistance of 10 ohms and a current of 2 amperes. What is the voltage
across the circuit?
2. If a power supply provides a voltage of 12 volts and the circuit has a resistance of 4
ohms, what is the current flowing through the circuit?
3. A light bulb has a resistance of 50 ohms and operates at a voltage of 120 volts. How
much current does is draw?
4. A circuit has a current of 5 amperes and a voltage of 20 volts. What is the resistance of
the circuit?
5. A resistor dissipates power at a rate of 12 watts when a current of 2 amperes passes
through it. What is the resistance of the resistor?
6. A circuit has a resistance of 8 ohms and draws a current of 3 amperes. What is the
power dissipated by the circuit?
7. A power supply delivers a current of 2 amperes to a circuit with a resistance of 15 ohms.
What is the power supplied by the sources?
8. A device operates at a power of 60 watts and has a voltage of 120 volts. What is the
current consumed by the device?
SAD Tutorial 01.
1. What is mean by feasibility study?
2. What is the importance of having a feasibility study report in a project?
3. Briefly discuss the four types of techniques used in feasibility study.

SAD Tutorial 02.


1. What are the project management phases consist of when creating project plans?
2. Briefly describe each of the following software development method ologies.
3. Compare the different between waterfall development and v-model development.
4. What are the key factors to consider when selecting a project methodology for a
software development project and how do these factors impact the overall success of
the project?
5. How does the agile development methodology promote collaboration, adaptability and
iterative progress in software development projects, and what are the key benefits of
adopting agile methodologies compared to traditional waterfall approaches?

SAD Tutorial 03.


1. What is a software development methodology and why is it important in the software
development process?
2. What are the main differences between traditional (waterfall) and iterative (agile)
Methodologies?
3. What are the key components of the Scram framework in Agile Methodology?
4. What are the challenges and considerations when selecting and implementing a specific
software development methodology for a project?
5. What is Agile methodology and what are its key principles and values?
6. How does Agile different from traditional waterfall methodology?

SAD Tutorial 04.


1. What are the differences between Traditional (Waterfall) and Agile approaches?
2. What are the key components of the Scrum framework in Agile methodology?

C# Lab 01.
1. Create a Console application that can read your name and batch as an input and print
them into the console.
2. Create a Console application that can read the radius from the user and calculate the
Area of a circle.
3. Create a console application that can read two input values and show the summation of
the inputs.
4. Create a console application that can read salary of an employee and tax rate. Then
show salary after the tax.

C# Lab 02.
1. Write a Console Application to calculate the sum of two user input numbers.
2. Write a Console Application to calculate sum, subtraction, multiplication and division of
two user input numbers.
3. Write a Console Application to calculate area and circumference of a circle for given
radius.
4. Write a Console Application to check if a given number is even or odd.
5. Upgrade the above console application which enables 10 user inputs and displays even
or odd for each user input.

C# Lab 03.
1. Write a C# program that takes an integer as input and checks whether it is even or odd.
Display the result “Even” or “Odd” accordingly.
2. Write a C# program that counts the number of vowels in a given string. Consider both
uppercase and lowercase vowels.
3. Write a C# program to find the sum of the digits of a given number using a for loop.
4. Write a C# program to calculate the sum of all the odd numbers from to a given positive
integer.
C# Lab 04.
Question 01.
1. Create a C# Console application to convert user given Kilo Meter (km) Value to Meter
(m) value. Take a separate Class call “ConvertValues” and inside the class create a
method call kilometerTOmeter. (No return type No Parameter Method). And display the
answer within the method. Then create an object in main Class (program class) and call
the method.
2. Modify the same user defined method to method which accepts a parameter value. That
parameter value is the user given Km value. (No return type with parameter method).
Display the answer by using the class object.
3. Modify the same user defined method to method which accept a parameter and returns
the answer at the end of the method. You should return the calculated Meter value at
the end of the method. (With return type with parameter method). Display the answer
by using object.

Question 02.
• Create a C# Console application to find the area and the circumference of a circle.
• User should insert the radius value to the program. Program should contain a separate
class call “FindValues” inside the separate class add two methods call findArea and
findCircumference Both these methods are methods which takes parameters. As the
parameter you should pass the radius value. By using above two methods find the area
and circumference of the circle and return the answer from both methods. Create a class
object in main class and call both methods and display the answers.

C# Lab 04.
Question 03.
Create the above mentioned console application and display it to the user. If user need to do an
Addition user need to insert 1 as the choice. For subtraction it should be 2 etc.
Your program should contain a separate class call “CalculateValues” and inside the class you
should add four methods which perform four arithmetic operations. All the methods should take
two parameters which are user inserted numbers.
And at the end of the method return the answer out of the method.
In main class if user want to do an addition call only the addition method in separate class.
If user want to do a subtraction call only the subtraction method in separate class. ETC.
And display the final answer as shown in the figure 01.

Question 04.
Add a separate class file to Console application program and create a method call private void
sayHello().
Inside the method display hello world.
In main class create object and try to access the sayHello() method by using the class object.
Can you access the method? Explain why?

Question 05.
Declare a Single dimensional array with 10 elements. Input the values to the array and find the
followings,

• Minimum value.
• Maximum value.
• Average value.
• Reverse order of values.
Hint – use a method which in separate class. And call the method from main the method.

You might also like