This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include "robot.h"
#include <iostream>
using namespace std;
void program_pulibot()
{
//set_instruction({0, West, South, East, North}, 1, 'T');
for(int i=-2;i<3;i++){
for(int j=-2;j<3;j++){
for(int k=-2;k<3;k++){
// cout << i << " " << j << " " << 0 << " " << k << " E" << endl;
set_instruction({0, i, j, 0, k}, 1, 'E');
}
}
}
for(int i=-2;i<3;i++){
for(int j=-2;j<3;j++){
for(int k=-2;k<3;k++){
if(j==0) continue;
// cout << i << " " << 0 << " " << j << " " << k << " S" << endl;
set_instruction({0, i, 0, j, k}, 1, 'S');
}
}
}
for(int i=-2;i<3;i++){
for(int j=-2;j<3;j++){
for(int k=-2;k<3;k++){
if(j==0) continue;
if(k==0) continue;
// cout << i << " " << 0 << " " << j << " " << k << " S" << endl;
if(j==-2 and k==-2){
{
// set_instruction({0, i, j, k, 0}, 1, 'T');
continue;}
}
set_instruction({0, i, j, k, 0}, 2, 'H');
}
}
}
for(int i=-2;i<3;i++){
for(int j=-2;j<3;j++){
for(int k=-2;k<3;k++){
if(j==0) continue;
if(i==0) continue;
if(k==0) continue;
if(i==-2 and j==-2){
{
// set_instruction({0, 0, i, j, k}, 1, 'T');
continue;}
}
// cout << i << " " << 0 << " " << j << " " << k << " S" << endl;
set_instruction({0, 0, i, j, k}, 2, 'H');
}
}
}
for(int i=-2;i<3;i++){
for(int j=-2;j<3;j++){
for(int k=-2;k<3;k++){
for(int l=-2;l<3;l++){
if(j==0) continue;
if(i==0) continue;
if(k==0) continue;
if(l==0) continue;
if(j==-2 and k==-2){
{//set_instruction({0, i, j, k, l}, 1, 'T');
continue;}
}
set_instruction({0, i, j, k, l}, 2, 'H');
}
}
}
}
for(int i=-2;i<3;i++){
for(int j=-2;j<3;j++){
for(int k=-2;k<3;k++){
for(int l=-2;l<3;l++){
if(j==-2 and k==-2){
{set_instruction({2, i, j, k, l}, 1, 'T');continue;}
}
if(i==0)
{set_instruction({2, i, j, k, l}, 1, 'W');continue;}
if(j==0)
{set_instruction({2, i, j, k, l}, 1, 'S');continue;}
if(k==0)
{set_instruction({2, i, j, k, l}, 1, 'E');continue;}
if(l==0)
{set_instruction({2, i, j, k, l}, 1, 'N');continue;}
if(i==1)
{set_instruction({2, i, j, k, l}, 2, 'W');continue;}
if(j==1)
{set_instruction({2, i, j, k, l}, 2, 'S');continue;}
if(k==1)
{set_instruction({2, i, j, k, l}, 2, 'E');continue;}
if(l==1)
{set_instruction({2, i, j, k, l}, 2, 'N');continue;}
}
}
}
}
for(int i=-2;i<3;i++){
for(int j=-2;j<3;j++){
for(int k=-2;k<3;k++){
for(int l=-2;l<3;l++){
if(j==-2 and k==-2){
{set_instruction({1, i, j, k, l}, 1, 'T');continue;}
}
if(i==0)
{set_instruction({1, i, j, k, l}, 1, 'W');continue;}
if(j==0)
{set_instruction({1, i, j, k, l}, 1, 'S');continue;}
if(k==0)
{set_instruction({1, i, j, k, l}, 1, 'E');continue;}
if(l==0)
{set_instruction({1, i, j, k, l}, 1, 'N');continue;}
if(i==1)
{set_instruction({1, i, j, k, l}, 2, 'W');continue;}
if(j==1)
{set_instruction({1, i, j, k, l}, 2, 'S');continue;}
if(k==1)
{set_instruction({1, i, j, k, l}, 2, 'E');continue;}
if(l==1)
{set_instruction({1, i, j, k, l}, 2, 'N');continue;}
}
}
}
}
for(int i=-2;i<3;i++){
for(int j=-2;j<3;j++){
// if(i==1 or j==1)continue;
// if(i==0 and j==0)continue;
// cout << i << " " << -2 << " " << -2 << " " << j << " T" << endl;
set_instruction({0, i, -2, -2, j}, 1, 'T');
}
}
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |