[C_C++]코딩테스트 연습/기타

    [그리디 문제풀기] Google Code Jam 2018 - Qualification Round (문제 B) (C/C++)

    [그리디 문제풀기] Google Code Jam 2018 - Qualification Round (문제 B) (C/C++)

    문제 B: 트리플 버블 정렬(Trouble Sort) Code Jam - Google’s Coding Competitions Put your coding skills to the test as you work your way through multiple rounds of algorithmic coding puzzles for the title of Code Jam Champ and 15,000 USD. codingcompetitions.withgoogle.com 간략한 문제 해석 원래 버블 정렬 알고리즘은 앞뒤의 두 원소를 비교해 크기가 더 작은 것이 앞으로 오도록 순서를 정렬하는 것이다. 이 문제에서는 인접한 두 원소가 아니라, 가운데에 어떤 원소를 기준으로 양옆의 원소를 비교해 크기가 작은 것이 앞..

    [그리디 문제풀기] Google Code Jam 2018 - Qualification Round (문제 A) (C/C++)

    [그리디 문제풀기] Google Code Jam 2018 - Qualification Round (문제 A) (C/C++)

    Code Jam - Google’s Coding Competitions Put your coding skills to the test as you work your way through multiple rounds of algorithmic coding puzzles for the title of Code Jam Champ and 15,000 USD. codingcompetitions.withgoogle.com 문제 A: 다시 우주를 구하기 (Saving The Universe Again) ↓ 문제 캡처 간략한 문제 해설 공격(Shoot)과 기 모으기(Charge)가 있다고 했을 때, Charge 시 데미지가 2배가 되어 공격력이 높아지고, Shoot 시 높아진 공격력으로 맞게 된다. 초기 데미지는 1이..