[Offer收割]编程练习赛21 register

Ended

Participants:295

Verdict:Accepted
Score:100 / 100
Submitted:2017-08-06 14:03:33

Lang:G++

Edit
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
//
// Created by  on 17/8/6.
//
#include <iostream>
using namespace std;
const int max_n = 300;
int l,f,r;
char d;
int n,m;
pair<int,int> now;
int mm[max_n][max_n][2];
int getdir(char c){
    if(c=='r'){
        return 1;
    }else if(c=='d'){
        return 0;
    }else if(c=='l'){
        return 3;
    }else if(c=='u'){
        return 2;
    }
}
void setwall(int dir,int l,int f,int r){
    if(dir==0){
        mm[now.first][now.second][0] = f;
        mm[now.first][now.second][1] = l;
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX