add basic implementation

parent 5b90c031
#include<iostream>
#include "sorting.h"
using namespace std;
vector<int> sort_custom(vector<int> v1){
int i, j;
int n=v1.size();
for (i = 0; i < n-1; i++) {
for (j = 0; j < n-i-1; j++){
if (v1[j] > v1[j+1])
swap(v1[j], v1[j+1]);
}
}
return v1;
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment