CMSACOR05P: Data Structures Lab
2. WAP using templates to sort a list of elements. Give user the option to perform sorting using Insertion sort, Bubble sort or Selection sort.
CMSACOR05P: Data Structures Lab
2. WAP using templates to sort a list of elements. Give user the option to perform sorting using Insertion sort, Bubble sort or Selection sort.
CMSACOR05P: Data Structures Lab
1. Write a program to search an element from a list. Give user the option to perform Linear or Binary search. Use Template functions.
9. WAP to print a triangle of stars as follows (take number of lines from user):
*5. Write a function that checks whether a given string is Palindrome or not. Use this function to find whether the string entered by user is Palindrome or not.
6. Write a function to find whether a given no. is prime or not. Use the same to generate the prime numbers less than 100.
8. Write a macro that swaps two numbers. WAP to use it
4. WAP to compute the sum of the first n terms of the following series, S =1-2+3-
4+5…………….
3. WAP to compute the sum of the first n terms of the following series,
S=1+1/2+1/3+1/4+……