#include <iostream> #include <vector> #include <algorithm> using namespace std; int main() { vector<int> v = {2, -4 ,3, -1}; int max = *max_element(v.begin(), v.end()); cout << max; // 3 }
CC-BY-SA 3.0 · Powered by MediaWiki
개인정보처리방침 · ABOUT