0% found this document useful (0 votes)
10 views2 pages

Programming Concepts and Algorithms

The document outlines various programming exercises, including identifying SUPERSPY numbers, performing binary searches, sorting arrays, and generating special arrays. It also covers method overloading, character bubble sort, prime number identification, matrix linear search, and a menu-driven program for special numbers. Each program includes user input and outputs specific results based on the provided data.

Uploaded by

rohitbose2468
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)
10 views2 pages

Programming Concepts and Algorithms

The document outlines various programming exercises, including identifying SUPERSPY numbers, performing binary searches, sorting arrays, and generating special arrays. It also covers method overloading, character bubble sort, prime number identification, matrix linear search, and a menu-driven program for special numbers. Each program includes user input and outputs specific results based on the provided data.

Uploaded by

rohitbose2468
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

Program 1: SUPERSPY Number

> Enter a number: 1021


> SUPERSPY number

Program 2: Binary Search


> Enter value to search: 20.8
> Search successful

Program 3: Selection Sort


> Enter 10 numbers:
> 23 12 45 9 18 1 6 55 3 30
> Sorted array:
> 1 3 6 9 12 18 23 30 45 55

Program 4: Special Array


> Enter 9 numbers:
> 4 5 6
> 5 3 2
> 4 2 5
> Special Array

Program 5: Method Overloading


> 1
> 1 2
> 1 2 3
> 1 2 3 4
> 1 2 3 4 5
> 1.0
> 1.414213562
> 1.732050807

Program 6: Character Bubble Sort


> Enter 10 characters:
> z y x w v u t s r q
> Sorted array:
> q r s t u v w x y z

Program 7: Series Generation


> 1 9 52 147 294 503 784 1147 1602 2149

Program 8: Prime Numbers in Array


> Enter 10 numbers:
> 3 4 5 6 7 8 9 10 11 12
> Prime numbers:
> 3 5 7 11

Program 9: Matrix Linear Search


> Enter 9 numbers:
> 1 2 3
> 4 5 6
> 7 8 9
> Enter number to search: 6
> Found at row 2, column 3

Program 10: Menu-Driven (Switch Case)


> 1. Special Number
> 2. Magic Number
> Enter your choice: 1
> Enter a number: 145
> Special Number

You might also like