답안 #643170

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
643170 2022-09-21T11:25:53 Z TimDee Climbers (RMI18_climbers) C++17
0 / 100
1 ms 212 KB
#include <bits/stdc++.h>
using namespace std;
#define forn(i,n) for (int i=0; i<n; ++i)

void solve() {

	cout<<"NO\n";
	return;
	int n; cin>>n;
	vector<int> a(n); forn(i,n) cin>>a[i];
	int ans=0;
	vector<int> v={0};
	for (int i=1; i<n; ++i) {
		if (a[i]>=v.back()) {
			for (int j=v.back()+1;j<=a[i];++j) v.push_back(j);
		} else {
			for (int j=v.back()-1;j>=a[i];--j) v.push_back(j);
		}
	}
	int l=0, r=v.size()-1;
	while (v[l+1]==v[r-1]) ++l, --r;
	cout<<ans;
}

int32_t main() {
	solve();
	return 0;
}
# 결과 실행 시간 메모리 Grader output
1 Incorrect 0 ms 212 KB Output isn't correct
2 Incorrect 0 ms 212 KB Output isn't correct
3 Incorrect 0 ms 212 KB Output isn't correct
4 Incorrect 0 ms 212 KB Output isn't correct
5 Incorrect 0 ms 212 KB Output isn't correct
# 결과 실행 시간 메모리 Grader output
1 Incorrect 0 ms 212 KB Output isn't correct
2 Incorrect 0 ms 212 KB Output isn't correct
3 Incorrect 0 ms 212 KB Output isn't correct
4 Incorrect 0 ms 212 KB Output isn't correct
5 Incorrect 0 ms 212 KB Output isn't correct
# 결과 실행 시간 메모리 Grader output
1 Incorrect 0 ms 212 KB Output isn't correct
2 Incorrect 1 ms 212 KB Output isn't correct
3 Incorrect 0 ms 212 KB Output isn't correct
4 Incorrect 0 ms 212 KB Output isn't correct
5 Incorrect 1 ms 212 KB Output isn't correct
6 Incorrect 1 ms 212 KB Output isn't correct
7 Incorrect 0 ms 212 KB Output isn't correct
8 Incorrect 0 ms 212 KB Output isn't correct
9 Incorrect 0 ms 212 KB Output isn't correct
10 Incorrect 0 ms 212 KB Output isn't correct