Skip to content

Commit fe9af10

Browse files
Merge pull request #537 from ashfreakingoyal/master
update
2 parents 261dfa6 + 08f5aba commit fe9af10

File tree

1 file changed

+13
-4
lines changed

1 file changed

+13
-4
lines changed

C++/Vector.cpp

+13-4
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,21 @@
1-
#include <iostream>
2-
#include <vector>
3-
#include <algorithm>
1+
#include <bits/stdc++.h>
42

53
using namespace std;
64

75
int main()
86
{
97
//Program to study vectors and see its different functions use
10-
vector<int> v;
8+
// vector<int> v;
9+
vector<int> v;
10+
vector<int> arr{ 1, 5, 8, 9, 6, 7, 3, 4, 2, 0 };
11+
12+
sort(arr.begin(), arr.end());
13+
14+
cout << "Sorted \n";
15+
for (int i=0;i<arr.size();i++)
16+
{ cout <<arr[i]<< " "; }
17+
cout<<"\n";
18+
1119
int n;
1220
v.reserve(469);
1321
cin>>n;
@@ -20,3 +28,4 @@ int main()
2028

2129
return 0;
2230
}
31+

0 commit comments

Comments
 (0)