Realign indentation and checkstyle of bracket (#29205)

* Realign indentation and checkstyle of bracket

* Update index.md
This commit is contained in:
seanjs
2019-02-25 04:17:43 -05:00
committed by Kristofer Koishigawa
parent f6b7958094
commit 30b630b5b7

View File

@ -196,12 +196,11 @@ int main(){
} }
``` ```
In C++11, you can also sort with lambda function, which can be useful. In C++11, you can also sort with lambda function, which can be useful.
```cpp11 ```cpp
#include<bits/stdc++.h> #include <bits/stdc++.h>
using namespace std; using namespace std;
int main() int main(){
{
vector<int > v {3, 1, 2}; vector<int > v {3, 1, 2};
sort(v.begin(), v.end(), [] (int i, int j) -> bool { sort(v.begin(), v.end(), [] (int i, int j) -> bool {
return i < j; return i < j;
@ -212,7 +211,7 @@ int main()
cout << e << " "; cout << e << " ";
} }
return 0; return 0;
} }
``` ```
### Sorting Vector In Descending Order ### Sorting Vector In Descending Order