1806 - 부분합
문제https://www.acmicpc.net/problem/1806느낀점응용 투포인터 문제, 조건 비교에서 등호를 넣으니 풀렸고 안 넣으니 풀리지 않았는데, 그 엣지케이스를 정확하게 모르겠음.. 어쨌든 등호도 신경 써야할 것이다~~풀이#include #include using namespace std;int main(){ int N, S; cin >> N >> S; vector arr(N); for (int i = 0; i > arr[i]; if (arr[i] == S) { cout = N || right >= N) { break; } if (sum
2025.02.23