Algorithm 136

C++ 알고리즘 - 백준 20920 영단어 암기는 괴로워 (맵, 벡터)

https://www.acmicpc.net/problem/20920 #include #define endl "\n"using namespace std;void CPP_INIT() { ios::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL);}bool compare(pair n1, pair n2) { if (n1.second == n2.second) { if (n1.first.size() == n2.first.size()) { return n1.first (n2.first.size()); } return n1.second > n2.second;}int main(void) { CPP_INIT(); int input1, input2; string str;..

Algorithm/백준 2025.01.17
C++ 알고리즘 - 백준 1010 다리 놓기

https://www.acmicpc.net/problem/1010 #include #define endl "\n"using namespace std;void CPP_INIT() { ios::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL);}int main(void) { CPP_INIT(); int in; cin >> in; for (int i = 0; i > input1 >> input2; double num = input2; double num1 = input1; if (input1 == 0) { cout  double 로 변수를 받고반올림 (round) 시킨 다음int로 다시 형변환 하여 해결 숫자가 큰 팩토리얼 문제에 유용할 듯

Algorithm/백준 2025.01.14