| # | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 | 
|---|---|---|---|---|---|---|---|
| 123573 | naderjemel | Bitaro the Brave (JOI19_ho_t1) | C++17 | 953 ms | 91148 KiB | 
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include <bits/stdc++.h>
using namespace std;
#define fi first
#define se second
#define pb push_back
#define mp make_pair
typedef long long ll;
typedef vector<int> vi;
typedef pair<int,int> ii;
typedef vector<pair<int,int> > vii;
int cumx[3005][3005];
int cumy[3005][3005];
int main(){
	int n,m;
	scanf("%d%d",&n,&m);
	vector<string> v(n);
	for(int i=0;i<n;i++){
		cin>>v[i];
	}
	for(int i=0;i<n;i++){
		for(int j=m-1;j>=0;j--){
			cumy[i][j]=cumy[i][j+1];
			if(v[i][j]=='O') cumy[i][j]++;
		}
	}
	for(int j=0;j<m;j++){
		for(int i=n-1;i>=0;i--){
			cumx[i][j]=cumx[i+1][j];
			if(v[i][j]=='I') cumx[i][j]++;
		}
	}
	ll rs=0;
	for(int i=0;i<n;i++){
		for(int j=0;j<m;j++){
			if(v[i][j]=='J'){
				rs+=cumx[i][j]*cumy[i][j];
			}
		}
	}
	printf("%lld\n", rs);
	return 0;
}
컴파일 시 표준 에러 (stderr) 메시지
| # | Verdict | Execution time | Memory | Grader output | 
|---|---|---|---|---|
| Fetching results... | ||||
| # | Verdict | Execution time | Memory | Grader output | 
|---|---|---|---|---|
| Fetching results... | ||||
| # | Verdict | Execution time | Memory | Grader output | 
|---|---|---|---|---|
| Fetching results... | ||||
