User Posts: royal52
0
5 Traits of a Great Logo Design
0

There are certain logos like Apple’s or Nike’s that are highly successful and lasting that they come to your mind just by merely mentioning the brand name. So ...

0
Function overloading in C++ with Examples
0

In programming languages, Function overloading is a process of declaring multiple member functions having same name but differ in one of the following ...

0
Function Overriding in C++ with examples
0

In C++ programming language, Functions overriding is a process of declaring the functions of same name and signatures as in a parent classes and a child ...

0
Multilevel Inheritance in C++ with examples
2

In programming, the multilevel inheritance is a technique or process in which a child class is inherited from another derived class. Let’s think of it in terms ...

0
Multiple Inheritance in C++ with examples
0

It is a process or mechanism in which a child class is inherited from two parent classes. Some programming languages allows multiple inheritance like C++ and ...

0
Inheritance in C++ with examples
1

Inheritance in C++ is a programming technique for producing a new class which has a properties and functionality of a class from which it is inherited. The ...

1
Insertion Sort in C++ with Examples
8

Insertion sort C++ is one of the most commonly used algorithm in C++ language for the sorting of fewer values or smaller arrays. It is preferred our Selection ...

0
Merge Sort in C++ with examples
1

Merge sort C++ is one of the very efficient algorithm in programming languages. It is normally used for the sorting of large data. Normally, Quicksort is ...

0
QuickSort in C++ with examples
5

QuickSort C++ is one of the fastest sorting algorithm in programming. Quick Sorting works on divide and conquer approach. It sorts the array in such a way so ...

0
About Us
1

In a nutshell, hellgeeks.com provides Answers to all Programming Problems, Analysis of technological trends, and Solutions to Everything Software which can ...

0
Selection Sort in C++ with Examples
4

In the following article we will discuss the sorting of arrays and elaborate the operations of selection sort with complete examples. Sorting of Arrays:- ...

1
Loops in C++ with Examples
1

What are Loops in C++:- Loop is the process of repetition of the certain steps until the given condition becomes false. They are always remains continue until ...

Browsing All Comments By: royal52
  1. just write if(array[j] lesser then array[j+1]) instead of if(array[j] greater then array[j+1]) and it will sort the array in descending order.

  2. I have updated my comment with a code block containing while loop, cheers.

  3. Okay, that’s the code of Bubble sort by using While Loop written in C++.

    while(i < 4) { int j = 0; while(j < 4) { if(array[j]>array[j+1])
    {
    hold=array[j];
    array[j]=array[j+1];
    array[j+1]=hold;
    }
    j++;
    }
    i++;
    }

    If you have any other questions then let me know, thanks.

  4. yes we can use a while loop.

  5. thanks for pointing out.

  6. thanks for pointing out !!!