[백준] 8958 - OX퀴즈 (파이썬) (C++)
[백준] 8958 - OX퀴즈 (파이썬) (C++)
2020.04.09N = int(input()) for i in range(N): score = 0 cnt = 0 result = input() for j in range(len(result)): if result[j] == 'O': cnt += 1 score += cnt elif result[j] == 'X': score += 0 cnt = 0 print(score) #include #include using namespace std; int main() { int num; cin >> num; int *save_total = new int[num]; for (int i = 0; i > answer; for..