We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding Bubble Sort.cpp
The text was updated successfully, but these errors were encountered:
This is the code for Bubble Sort: Please merge this pull request that I made to solve the issue. And consider this answer as the 1st comment.
`#include
using namespace std;
int main() {
int arr[] = {5,1,3,6,4,2}; int a; //loop for BUBBLE SORT for(int i = 0; i < 6; i++) { for(int j = i+1; j < 6; j++) { if(arr[i] > arr[j]) { a = arr[j]; //a = 1 arr[j] = arr[i]; //arr[1] = arr[0] = 5 arr[i] = a; //arr[0] = 1 } } } //for priting array for(int j = 0; j < 6; j++) { cout<<arr[j]<<" "; } return 0;
}`
Sorry, something went wrong.
Please assign this issue to me.
No branches or pull requests
Adding Bubble Sort.cpp
The text was updated successfully, but these errors were encountered: