#include <iostream>
#include<vector>
#include <algorithm>
using namespace std;

int main() {

    
    vector<int> v1 = {2,4,2,5,1};
    sort(v1.begin(),v1.end());
    reverse(v1.begin(),v1.end());
   
    cout << *v1.begin() << "\n";

    vector<int> v2 = {2,3,3,5,7,8,8,8};
    auto a = lower_bound(v2.begin(),v2.end(),5);
    auto b = upper_bound(v2.begin(),v2.end(),5);
    cout << *a << " " << *b << "\n"; // 5 7

    std::cout << "**Happy Coding My Daer Students***!" << std::endl;
    return 0;
}

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: