## Bubble sort

There are different sorting algorithms are available like selection sort, insertion sort etc. In this article we learn about one of them sorting algorithm, working of this sorting algorithm and example of this sorting algorithm. Bubble sort algorithm is the simplest sorting algorithm as compare to other sorting algorithms. In the bubble sorting algorithm, array is traversed from first element to last element. In this sorting, compare the...

## Binary search

Binary search is one of the fundamental algorithms in computer science. In order to explore it, we’ll first build up a theoretical backbone, then use that to implement the algorithm properly and avoid those nasty off-by-one errors everyone’s been talking about. Finding a value in a sorted sequence In its simplest form, binary search isused to quickly find a value in a sorted sequence (consider a sequence anordinary...

## Binary Search Program

There are two types of searching are possible. First is linear search and second is binary search. In this article we explain about the binary search program, if you want to learn about what is linear search and how it works? see this article Linear Search. The linear search and binary search are used to find the key element in a given multiple elements and displays the position...

## Declare, Instantiate and Initialize the Arrays

In this article we learn how to declare instantiate and initialize the array. Arrays are nicely organized lists of data. Think of a numbered list that starts at zero and extends one line every time you add something to the list. Arrays are useful for any number of situations because they’re treated as a single hunk of data. Here we will see how to declare array and how...

## Arrays

Arrays are nicely organized lists of data. Array is a collection of the homogeneous data types. Think of a numbered list that starts at zero and extends one line every time you add something to the list. The arrays are useful for any number of situations because they’re treated as a single hunk of data. The array is one of the most important part in a any of...

## Swapping of Two Numbers

Here we will see the swapping of two numbers using two different methods. In first method we exchange the values using the temporary variables and in second method Swapping of numbers without temporary variable. Swapping of numbers is the way of exchanging the values in the variables. Suppose there are two variables a and b, The variable a has a value 15 and the variable b has the...