0% found this document useful (0 votes)
5 views

PICL Assi 6 7 _Write a C Program to Write a C program for binary serach and matrix operations

The document outlines lab assignments for Sayantan Nandi in the CSE program at Symbiosis Institute of Technology for the academic year 2024-25. Assignment 6 focuses on implementing a binary search algorithm in C, discussing its efficiency compared to linear search, while Assignment 7 involves matrix operations such as addition, subtraction, and transpose. Both assignments include theory questions, practice tasks, and conclusions reflecting on the learning outcomes and challenges faced.
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views

PICL Assi 6 7 _Write a C Program to Write a C program for binary serach and matrix operations

The document outlines lab assignments for Sayantan Nandi in the CSE program at Symbiosis Institute of Technology for the academic year 2024-25. Assignment 6 focuses on implementing a binary search algorithm in C, discussing its efficiency compared to linear search, while Assignment 7 involves matrix operations such as addition, subtraction, and transpose. Both assignments include theory questions, practice tasks, and conclusions reflecting on the learning outcomes and challenges faced.
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 16

Symbiosis Institute of Technology

Faculty of Engineering
CSE- Academic Year 2024-25
Data Structures – Lab Batch 2023-27
Lab Assignment No:- 6

Name of Student SAYANTAN NANDI


PRN No. 24070122176
Batch 24-28
Class CS C1
Academic Year & 1ST YEAR 2ND SEMESTER
Semester

Date of Performance 17-02-2025

Title of Assignment: Write a C program of binary search for a user-given element in a set
of ‘n’ numbers.

Theory Questions: ● What is the time complexity of the binary search algorithm?
● How does binary search differ from linear search in terms of
efficiency?
● Can binary search be applied to an unsorted array? Why or why
not?

Algorithm & Flow


Chart and Source
Code
Output Screenshots

Practice questions a. Implement a modified version of the binary search that returns the
count of occurrences of the target element in the array.

b. Explore and implement the recursive version of the binary search


algorithm in C.
Conclusion In conclusion, the implementation of the binary search algorithm in the C
program provides an
efficient way to locate a user-given element within a sorted set of 'n'
numbers. The algorithm
demonstrates the importance of a sorted input array for optimal search
performance.

Lab Assignment No:- 7

Name of Student SAYANTAN NANDI


PRN No. 24070122176
Batch 24-28
Class CS C1
Academic Year & 1ST YEAR 2ND SEMESTER
Semester

Date of Performance 17-02-2025

Title of Assignment: Write a C program to perform matrix operations like addition,


subtraction and transpose

Theory Questions: ● Explain the importance of the transpose operation in real-world


scenarios.
● What modifications would you make to the program to handle
square matrices efficiently?

Algorithm & Flow


Chart and Source
Code
Output Screenshots
Practice questions ● Implement a C program to multiply two matrices.
● Implement a C program to find Upper triangular matrix
● Implement a C-program to add diagonal matrix elements.

Conclusion Summarize the key learnings from the experiment.


● Reflect on the challenges faced and how they were overcome.
● Discuss the significance of matrix operations in various applications.

You might also like