Click here to Skip to main content
15,038,237 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
Was told to write a program that demonstrates bubble sort algorithm in c++

What I have tried:

Wasn’t able to try anything. Looking at the question I couldn’t move
Posted
Updated 19-Jul-21 19:52pm

While we are more than willing to help those that are stuck, that doesn't mean that we are here to do it all for you! We can't do all the work, you are either getting paid for this, or it's part of your grades and it wouldn't be at all fair for us to do it all for you.

So we need you to do the work, and we will help you when you get stuck. That doesn't mean we will give you a step by step solution you can hand in!
Start by explaining where you are at the moment, and what the next step in the process is. Then tell us what you have tried to get that next step working, and what happened when you did.

If you are having problems getting started at all, then this may help: How to Write Code to Solve a Problem, A Beginner's Guide[^]
   
Comments
CPallini 20-Jul-21 1:51am
   
5.
Start by reading up on what the Bubble Sort algorithm is and how it works.

Bubble sort - Wikipedia[^]

After that, it's up to you to write the code to do it.
   
Comments
CPallini 20-Jul-21 1:51am
   
5.
You may visit and read some Learn C++ tutorial to know how to write the code.

some tips to improve your result:
- write some comments in code
- write some test code with data to verify your code
- use idention and braces
- write "clean code" with using function and variable names which are describing what their purpose is
   

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)




CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900