이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include <bits/stdc++.h>
#define ll long long
#define pii pair<int,int>
#define pll pair<ll,ll>
#define vi vector<int>
#define vl vector<ll>
#define mp make_pair
#define pb push_back
using namespace std;
int n, m;
char mat[4001][4001];
int main(){
cin>>n>>m;
bool f = false, r = false;
for(int i = 0; i < n; i++){
for(int j =0 ; j < m; j++){
cin>>mat[i][j];
if(mat[i][j] =='F')
f = true;
if(mat[i][j] == 'R')
r = true;
}
}
cout<<f + r<<endl;
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |