Submission #738531

#TimeUTC-0UsernameProblemLanguageResultExecution timeMemory
7385312023-05-09 03:48:031075508020060209tcSelotejp (COCI20_selotejp)C++14
110 / 110
104 ms120620 KiB
#include<bits/stdc++.h>
using namespace std;
#define int long long
int n;int m;
string gr[1010];
int dp[1010][12][2510];
signed main(){
cin>>n>>m;
for(int i=1;i<=n;i++){
cin>>gr[i];
}
for(int i=0;i<=n;i++){
for(int j=0;j<m;j++){
for(int A=0;A<(1<<m);A++){
dp[i][j][A]=1e9;
}
}
}
dp[0][m-1][0]=0;
for(int i=0;i<=n;i++){
for(int j=0;j<m-1;j++){
for(int A=0;A<(1<<m);A++){
//
if(gr[i][j+1]=='#'&& ((A&(1<<(j+1)))!=0) ){
 
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...