Submission #910479

#TimeUsernameProblemLanguageResultExecution timeMemory
910479ByeWorldTracks in the Snow (BOI13_tracks)C++14
2.19 / 100
96 ms33896 KiB
#include <bits/stdc++.h> #pragma GCC optimize("Ofast,unroll-loops") #define bupol __builtin_popcount //#define int long long #define ll long long #define ld long double #define fi first #define se second #define pb push_back #define lf (id<<1) #define rg ((id<<1)|1) #define md ((l+r)>>1) using namespace std; const int MAXN = 2e5+5; const int MAXK = 205; const int LOG = 20; const int MOD = 1e9+7; const int SQRT = 520; const int INF = 1e9+10; typedef pair<ll,ll> pii; typedef pair<ll,pii> ipii; int h, w; string s[4010]; signed main(){ ios_base::sync_with_stdio(0);cin.tie(0);cout.tie(0); cin >> h >> w; for(int i=0; i<h; i++){ cin >> s[i]; } int ans = 0, an = 0; set<char> x; for(int i=0; i<h; i++){ for(int j=0; j<w; j++){ if(s[i][j]=='.') continue; if(s[i][j] == 'F') ans = 1; else if(s[i][j] == 'R') an = 1; } } cout << ans+an << '\n'; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...