Searching Logic in C++

Searching Logic in C++

Searching Logic in C++ :

Every computer user in use some kind of Software to Create, Read & Edit some kind of text file everyone use Search feature to Search a name in a document to find a spell mistake in the document those who use computer for official purpose only are not interested in knowing how the things are happening on back end but being computer science student one should know how the things are going in at the back end lets come to the topic “Searching” Do you know when ever you press Ctrl+F and put a word a number to find the document what happens at the back to find your word number?

If you don’t know let me tell you there are lots of Searching algorithm we use depends on condition.

But here I am going to show you the basic logic behind the searching process via a C++ code.

I am hopping you know how to try Run the Code.

Searching Logic in C++ Here is the Code

Code Explanation:

The Code consist on 2 parts in 1st part Program is asking user to enter data (Data in integer form) which program gonna store in an array.

In 2nd part of program, program ask user to enter the number which He want to search and then program search the number for user.

This is not the logic every one using in Computer Science there are lots of other searching algos. are available for different scenarios but this is the logic on a basic level to clarify the minds of students how the things are happening.

Leave a Reply

Your email address will not be published. Required fields are marked *