buggy_code stringlengths 11 625k | fixed_code stringlengths 17 625k | bug_type stringlengths 2 4.45k | language int64 0 8 | token_count int64 5 200k |
|---|---|---|---|---|
n=int(input())
ns=input().split()
for i in range(len(ns)):
ns[i]=int(ns[i])
a=sum(ns)
i=min(ns)
u=max(ns)
print(amin,amax,asum)
| n=int(input())
ns=input().split()
for i in range(len(ns)):
ns[i]=int(ns[i])
asum=sum(ns)
amin=min(ns)
amax=max(ns)
print(amin,amax,asum)
| [["-", 36, 36, 0, 656, 0, 1, 0, 662, 31, 22], ["+", 36, 36, 0, 656, 0, 1, 0, 662, 31, 22]] | 5 | 66 |
length = int(input())
arr = input().split()
iniV = int(arr[0])
mi = iniV
mx = iniV
su = iniV
for s in arr:
val = int(s)
su += val
if(val < mi):
mi = val
if(val > mx):
mx = val
print(mi, mx, su)
| length = int(input())
arr = input().split()
iniV = int(arr[0])
mi = iniV
mx = iniV
su = 0
for s in arr:
val = int(s)
su += val
if(val < mi):
mi = val
if(val > mx):
mx = val
print(mi, mx, su)
| [["-", 36, 36, 0, 656, 0, 1, 0, 662, 12, 22], ["+", 36, 36, 0, 656, 0, 1, 0, 662, 12, 612]] | 5 | 77 |
n = int(input())
x = input()
x = x.split(" ")
x = list(map(int,x))
print("%d %d %d" %(max(x),min(x),sum(x)))
| n = int(input())
x = input()
x = x.split(" ")
x = list(map(int,x))
print("%d %d %d" %(min(x),max(x),sum(x)))
| [["-", 3, 4, 0, 657, 12, 660, 0, 652, 63, 22], ["+", 3, 4, 0, 657, 12, 660, 0, 652, 63, 22]] | 5 | 57 |
n = int(input())
nums = input().split()
su = 0
ma = -1000000
mi = 1000000
for v in range(n):
num = int(nums[v])
if num > ma:
ma = num
elif num < mi:
mi = num
su += num
print(mi, ma, su)
| n = int(input())
nums = input().split()
su = 0
ma = -1000000
mi = 1000000
for v in range(n):
num = int(nums[v])
if num > ma:
ma = num
if num < mi:
mi = num
su += num
print(mi, ma, su)
| [["-", 0, 7, 8, 196, 0, 57, 75, 665, 0, 683], ["+", 0, 656, 0, 7, 8, 196, 0, 57, 0, 121]] | 5 | 71 |
n = input()
s = 0
a = input()
b = a.split(" ")
c = []
for i in range(n):
c.append(int(b[i]))
for u in c:
s=s+u
print(min(c),max(c),s)
| n = input()
s = 0
a = input()
b = a.split(" ")
c = []
for i in range(int(n)):
c.append(int(b[i]))
for u in c:
s=s+u
print(min(c),max(c),s)
| [["+", 0, 7, 12, 652, 3, 4, 0, 652, 63, 22], ["+", 12, 652, 3, 4, 0, 652, 3, 4, 0, 24], ["+", 12, 652, 3, 4, 0, 652, 3, 4, 0, 25]] | 5 | 71 |
#include <stdio.h>
int main(void) {
int H, W, i = 1, j = 1;
while (1) {
scanf("%d%d", &H, &W);
if (H == 0 && W == 0)
break;
while (H >= i) {
while (W >= j) {
if (i == 1 || i == H || j == 1 || j == W)
printf("#");
else {
printf(".");
}
j++;
... | #include <stdio.h>
int main(void) {
int H, W, i = 1, j = 1;
while (1) {
scanf("%d%d", &H, &W);
if (H == 0 && W == 0)
break;
while (H >= i) {
while (W >= j) {
if (i == 1 || i == H || j == 1 || j == W)
printf("#");
else {
printf(".");
}
j++;
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 1 | 128 |
#include <stdio.h>
int main() {
int H, W;
while (1) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0)
break;
for (int j = 1; j <= H; j++) {
for (int i = 1; i <= W; i++) {
if (j == 1 || j == H) {
printf("#");
} else {
if (i == 1 || i == W)
printf(... | #include <stdio.h>
int main() {
int H, W;
while (1) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0)
break;
for (int j = 1; j <= H; j++) {
for (int i = 1; i <= W; i++) {
if (j == 1 || j == H) {
printf("#");
} else {
if (i == 1 || i == W)
printf(... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 1 | 130 |
#include <iostream>
using namespace std;
int main() {
int h, w;
while (1) {
cin >> h >> w;
if (h == 0 && w == 0)
break;
for (int i = 1; i <= h; i++) {
for (int j = 1; j <= w; j++) {
if (i == 1 || i == h)
cout << "#";
else if (j == 1 || j == w) {
cout << "... | #include <iostream>
using namespace std;
int main() {
int h, w;
while (1) {
cin >> h >> w;
if (h == 0 && w == 0)
break;
for (int i = 1; i <= h; i++) {
for (int j = 1; j <= w; j++) {
if (i == 1 || i == h)
cout << "#";
else if (j == 1 || j == w) {
cout << "... | [["-", 0, 7, 8, 9, 0, 1, 0, 16, 17, 151], ["-", 0, 7, 8, 9, 0, 1, 0, 16, 12, 22], ["+", 0, 52, 8, 9, 0, 1, 0, 16, 31, 22], ["+", 0, 52, 8, 9, 0, 1, 0, 16, 17, 151], ["+", 8, 9, 0, 1, 0, 16, 12, 5, 0, 62], ["+", 8, 9, 0, 1, 0, 16, 12, 5, 0, 44], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 1 | 128 |
#include <iostream>
#include <stdio.h>
using namespace std;
int main() {
int h, w, i, j;
char s = '#', x = '.';
while (1) {
cin >> h >> w;
if (h == 0 && w == 0)
break;
for (j = 0; j < w; j++) {
cout << s;
}
printf("\n");
for (i = 0; i < h - 2; i++) {
cout << s;
for ... | #include <iostream>
#include <stdio.h>
using namespace std;
int main() {
int h, w, i, j;
char s = '#', x = '.';
while (1) {
cin >> h >> w;
if (h == 0 && w == 0)
break;
for (j = 0; j < w; j++) {
cout << s;
}
printf("\n");
for (i = 0; i < h - 2; i++) {
cout << s;
for ... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 1 | 168 |
#include <iostream>
using namespace std;
int main() {
int H, W;
while (1) {
cin >> H >> W;
if (H == 0 && W == 0)
break;
for (int i = 0; i < H; i++) {
for (int j = 0; j < W; j++) {
if (i == 0 || j == 0 || j == W - 1 || i == H - 1) {
cout << '#';
}
cout << '.'... | #include <iostream>
using namespace std;
int main() {
int H, W;
while (1) {
cin >> H >> W;
if (H == 0 && W == 0)
break;
for (int i = 0; i < H; i++) {
for (int j = 0; j < W; j++) {
if (i == 0 || j == 0 || j == W - 1 || i == H - 1) {
cout << "#";
} else
cout... | [["-", 64, 9, 0, 1, 0, 16, 12, 103, 0, 104], ["+", 64, 9, 0, 1, 0, 16, 12, 5, 0, 62], ["+", 0, 7, 8, 9, 0, 57, 75, 76, 0, 95], ["-", 8, 9, 0, 1, 0, 16, 12, 103, 0, 104], ["+", 75, 76, 0, 1, 0, 16, 12, 5, 0, 62]] | 1 | 120 |
#include <bits/stdc++.h>
using namespace std;
int main() {
while (1) {
int h, w;
cin >> h >> w;
if (h == 0 && w == 0)
break;
for (int i = 0; i < h; i++) {
for (int j = 0; j < w; j++) {
if (i == 0 || i == h - 1 || j == 0 || j == w - 1)
cout << ".";
else
... |
#include <bits/stdc++.h>
using namespace std;
int main() {
while (1) {
int h, w;
cin >> h >> w;
if (h == 0 && w == 0)
break;
for (int i = 0; i < h; i++) {
for (int j = 0; j < w; j++) {
if (i == 0 || i == h - 1 || j == 0 || j == w - 1)
cout << "#";
else
... | [["-", 0, 57, 64, 1, 0, 16, 12, 5, 0, 6], ["+", 0, 57, 64, 1, 0, 16, 12, 5, 0, 6], ["-", 75, 76, 0, 1, 0, 16, 12, 5, 0, 6], ["+", 75, 76, 0, 1, 0, 16, 12, 5, 0, 6]] | 1 | 119 |
#include <cstdio>
#include <iostream>
using namespace std;
int main() {
int H, W;
while (1) {
cin >> H >> W;
if (H == 0 && W == 0) {
break;
} else {
for (int i = 0; i < W; i++) {
cout << "#";
}
puts("");
for (int i = 1; i < H - 1; i++) {
cout << "#";
... | #include <cstdio>
#include <iostream>
using namespace std;
int main() {
int H, W;
while (1) {
cin >> H >> W;
if (H == 0 && W == 0) {
break;
} else {
for (int i = 0; i < W; i++) {
cout << "#";
}
puts("");
for (int i = 1; i < H - 1; i++) {
cout << "#";
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 1 | 167 |
#include <stdio.h>
using namespace std;
// scanf("%d%d",&W,&H);
// printf("%d\n",c);
int main() {
int H, W, j, i;
i = 1;
j = 1;
while (1) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0)
break;
while (i < W + 1) { //上枠
i = i + 1;
printf("#");
}
i = 1;
printf("\n");
... | #include <stdio.h>
using namespace std;
// scanf("%d%d",&W,&H);
// printf("%d\n",c);
int main() {
int H, W, j, i;
i = 1;
j = 1;
while (1) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0)
break;
while (i < W + 1) { //上枠
i = i + 1;
printf("#");
}
i = 1;
printf("\n");
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 1 | 200 |
#include <stdio.h>
int main() {
int H;
int W;
while (true) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0) {
break;
}
for (int hol = 0; hol < W; hol++) {
printf("#");
}
printf("\n");
for (int var = 0; var < H - 2; var++) {
printf("#");
for (int hol = 1; hol... | #include <stdio.h>
int main() {
int H;
int W;
while (true) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0) {
break;
}
for (int hol = 0; hol < W; hol++) {
printf("#");
}
printf("\n");
for (int var = 0; var < H - 2; var++) {
printf("#");
for (int hol = 1; hol... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 1 | 168 |
#include <stdio.h>
int main() {
int i;
int j;
int H;
int W;
while (true) {
scanf("%d%d", &H, &W);
if (H == 0 && W == 0) {
break;
}
for (i = 0; i < H; i++) {
for (j = 0; j < W; j++) {
if (j == 0 || j == W - 1 || i == 0 || i == H - 1) {
printf("#");
... | #include <stdio.h>
int main() {
int i;
int j;
int H;
int W;
while (true) {
scanf("%d%d", &H, &W);
if (H == 0 && W == 0) {
break;
}
for (i = 0; i < H; i++) {
for (j = 0; j < W; j++) {
if (j == 0 || j == W - 1 || i == 0 || i == H - 1) {
printf("#");
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 1 | 134 |
#include <cstdio>
#include <iostream>
using namespace std;
int main() {
int H, W;
while (1) {
cin >> H >> W;
if (H == 0 && W == 0)
break;
for (int i = 0; i < H; i++) {
for (int j = 0; j < W; j++) {
if (i != 0 && i != H - 1 && j != 0 && j != W - 1) {
printf(".");
... | #include <cstdio>
#include <iostream>
using namespace std;
int main() {
int H, W;
while (1) {
cin >> H >> W;
if (H == 0 && W == 0)
break;
for (int i = 0; i < H; i++) {
for (int j = 0; j < W; j++) {
if (i != 0 && i != H - 1 && j != 0 && j != W - 1) {
printf(".");
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 1 | 126 |
#include <iostream>
using namespace std;
int main() {
int H, W;
while (1) {
cin >> H >> W;
if (H == 0 && W == 0)
break;
for (int i = 0; i < H; i++) {
for (int j = 0; j < W; j++) {
if (i >= 1 && i < H - 1 && j >= 1 && j < W - 1) {
cout << ".";
} else {
... | #include <iostream>
using namespace std;
int main() {
int H, W;
while (1) {
cin >> H >> W;
if (H == 0 && W == 0)
break;
for (int i = 0; i < H; i++) {
for (int j = 0; j < W; j++) {
if (i >= 1 && i < H - 1 && j >= 1 && j < W - 1) {
cout << ".";
} else {
... | [["+", 0, 52, 8, 9, 0, 1, 0, 16, 31, 22], ["+", 0, 52, 8, 9, 0, 1, 0, 16, 17, 151], ["+", 8, 9, 0, 1, 0, 16, 12, 5, 0, 62], ["+", 8, 9, 0, 1, 0, 16, 12, 5, 0, 44], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 1 | 121 |
#include <cstdio>
#include <iostream>
using namespace std;
#define MAX 300
int main(void) {
int H, W;
while (1) {
cin >> W >> H;
if (H == 0 && W == 0)
break;
for (int i = 0; i < H; i++) {
for (int j = 0; j < W; j++) {
if (i == 0 || i == W || j == 0 || j == W - 1)
printf(... | #include <cstdio>
#include <iostream>
using namespace std;
#define MAX 300
int main(void) {
int H, W;
while (1) {
cin >> H >> W;
if (H == 0 && W == 0)
break;
for (int i = 0; i < H; i++) {
for (int j = 0; j < W; j++) {
if (i == 0 || i == H - 1 || j == 0 || j == W - 1)
pri... | [["-", 8, 9, 0, 1, 0, 16, 31, 16, 12, 22], ["-", 0, 52, 8, 9, 0, 1, 0, 16, 17, 152], ["+", 0, 52, 8, 9, 0, 1, 0, 16, 17, 152], ["+", 0, 52, 8, 9, 0, 1, 0, 16, 12, 22], ["-", 51, 16, 31, 16, 31, 16, 12, 16, 12, 22], ["+", 31, 16, 31, 16, 12, 16, 12, 16, 31, 22], ["+", 31, 16, 31, 16, 12, 16, 12, 16, 17, 33], ["+", 31, 1... | 1 | 131 |
#include <stdio.h>
int main(void) {
int a, s, d, f, g, h, j, i;
while (1) {
scanf("%d %d", &a, &s);
if (a == 0 && s == 0)
break;
for (i = 0; i < s; i++)
printf("#");
printf("\n");
for (i = 1; i < a - 1; i++) {
printf("#");
for (j = 1; j < s - 1; j++)
printf(".");
... | #include <stdio.h>
int main(void) {
int a, s, d, f, g, h, j, i;
while (1) {
scanf("%d %d", &a, &s);
if (a == 0 && s == 0)
break;
for (i = 0; i < s; i++)
printf("#");
printf("\n");
for (i = 1; i < a - 1; i++) {
printf("#");
for (j = 1; j < s - 1; j++)
printf(".");
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 1 | 176 |
while True:
H,W=[int() for x in input().split()]
if H == 0 and W == 0:
break
for a in range (H):
if a == 0 or a == H-1:
print("#"*W)
else:
print("#" + "."*(W-2) + "#")
| while True:
H,W=[int(x) for x in input().split()]
if H == 0 and W == 0:
break
for a in range (H):
if a == 0 or a == H-1:
print("#"*W)
else:
print("#" + "."*(W-2) + "#")
print('')
| [["+", 0, 662, 12, 658, 8, 652, 3, 4, 0, 22], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 25], ["+", 0, 52, 8, 196, 0, 1, 0, 652, 63, 22], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 24], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 654], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 655]] | 5 | 81 |
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
while (true) {
int w = sc.nextInt();
int h = sc.nextInt();
if (w == 0 && h == 0)
break;
if (w == 1 && h == 1)
System.out.println("#");
el... | import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
while (true) {
int h = sc.nextInt();
int w = sc.nextInt();
if (w == 0 && h == 0)
break;
if (w == 1 && h == 1)
System.out.println("#");
el... | [["-", 0, 52, 8, 196, 0, 503, 49, 200, 141, 22], ["+", 0, 52, 8, 196, 0, 503, 49, 200, 141, 22]] | 3 | 224 |
import java.util.*;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
while (true) {
int h = sc.nextInt();
int w = sc.nextInt();
if (h == 0 && w == 0) {
break;
}
for (int i = 1; i <= w; i++) {
for (int j = 1; j <=... | import java.util.*;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
while (true) {
int w = sc.nextInt();
int h = sc.nextInt();
if (h == 0 && w == 0) {
break;
}
for (int i = 1; i <= w; i++) {
for (int j = 1; j <=... | [["-", 0, 52, 8, 196, 0, 503, 49, 200, 141, 22], ["+", 0, 52, 8, 196, 0, 503, 49, 200, 141, 22]] | 3 | 164 |
#include <stdio.h>
int main() {
int H, W;
int i, j;
while (1) {
scanf("%d %d", &H, &W);
printf("\n");
if (H == 0 && W == 0)
break;
for (i = 0; i < H; i++) {
for (j = 0; j < W; j++) {
if ((i + j) % 2 == 0) {
printf("#");
}
if ((i + j) % 2 == 1) {
... | #include <stdio.h>
int main() {
int H, W;
int i, j;
while (1) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0)
break;
for (i = 0; i < H; i++) {
for (j = 0; j < W; j++) {
if ((i + j) % 2 == 0) {
printf("#");
}
if ((i + j) % 2 == 1) {
printf(".");... | [["-", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["-", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["-", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["-", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["-", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["-", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 145 |
#include <stdio.h>
int main(void) {
int H, W;
int i, j;
while (1) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0) {
break;
}
for (i = 0; i < H; i++) {
for (j = 0; j < W; j++) {
if (i % 2 == j % 2) {
printf("#");
} else {
printf(".");
}
... | #include <stdio.h>
int main(void) {
int H, W;
int i, j;
while (1) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0) {
break;
}
for (i = 0; i < H; i++) {
for (j = 0; j < W; j++) {
if (i % 2 == j % 2) {
printf("#");
} else {
printf(".");
}
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 121 |
#include <stdio.h>
int main(void) {
int H, W, i, j;
while (1) {
scanf("%d%d", &H, &W);
if (H == 0 && W == 0)
break;
for (i = 0; i < H; i++) {
if (i % 2 == 0) {
for (j = 0; j < W; j++) {
if (j % 2 == 0)
putchar('#');
else
putchar('.');
... | #include <stdio.h>
int main(void) {
int H, W, i, j;
while (1) {
scanf("%d%d", &H, &W);
if (H == 0 && W == 0)
break;
for (i = 0; i < H; i++) {
if (i % 2 == 0) {
for (j = 0; j < W; j++) {
if (j % 2 == 0)
putchar('#');
else
putchar('.');
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 103, 0, 104], ["+", 0, 1, 0, 2, 3, 4, 0, 103, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 163 |
#include <math.h>
#include <stdio.h>
int main() {
int H, W, i, j;
/*
while(1){
scanf("%d %d",&H,&W);
if(H == 0 && W == 0){
break;
}
for(i = 0;i < H;i++){
if(i % 2 == 0){
for(j = 0;j < W;j++){
if(j % 2 == 0){
printf("#");
}
else{
... | #include <math.h>
#include <stdio.h>
int main() {
int H, W, i, j;
/*
while(1){
scanf("%d %d",&H,&W);
if(H == 0 && W == 0){
break;
}
for(i = 0;i < H;i++){
if(i % 2 == 0){
for(j = 0;j < W;j++){
if(j % 2 == 0){
printf("#");
}
else{
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 120 |
#include <stdio.h>
int main(void) {
int H = 0, W = 0;
int i = 0, j = 0;
for (;;) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0) {
break;
} else {
for (i = 0; i < H; i++) {
for (j = 0; j < W; j++) {
putchar((i + j) % 2 == 0 ? '#' : '.');
/*if( j % 2 == 0){
... | #include <stdio.h>
int main(void) {
int H = 0, W = 0;
int i = 0, j = 0;
for (;;) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0) {
break;
} else {
for (i = 0; i < H; i++) {
for (j = 0; j < W; j++) {
putchar((i + j) % 2 == 0 ? '#' : '.');
/*if( j % 2 == 0){
... | [["+", 75, 76, 0, 9, 0, 1, 0, 2, 63, 22], ["+", 0, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 0, 57, 75, 76, 0, 9, 0, 1, 0, 35]] | 0 | 125 |
/*
* Print a Rectangle.c
*
* Created on: 2015/02/13
*
*/
#include <stdio.h>
int main(void) {
int H, W;
int i, j;
while (1) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0)
break;
for (i = 0; i < H; i++) {
for (j = 0; j < W; j++) {
if ((i + j) % 2 == 0)
printf("#... | /*
* Print a Rectangle.c
*
* Created on: 2015/02/13
*
*/
#include <stdio.h>
int main(void) {
int H, W;
int i, j;
while (1) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0)
break;
for (i = 0; i < H; i++) {
for (j = 0; j < W; j++) {
if ((i + j) % 2 == 0)
printf("#... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 118 |
#include <stdio.h>
int main(void) {
int h, w, counth, countw = 0;
while (1) {
scanf("%d %d", &h, &w);
if (h == 0 && w == 0)
break;
for (counth = 0; counth < h; counth++) {
if (counth % 2 == 0) {
while (countw < w) {
printf("#");
countw++;
if (countw == w... | #include <stdio.h>
int main(void) {
int h, w, counth, countw = 0;
while (1) {
scanf("%d %d", &h, &w);
if (h == 0 && w == 0)
break;
for (counth = 0; counth < h; counth++) {
if (counth % 2 == 0) {
while (countw < w) {
printf("#");
countw++;
if (countw == w... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 163 |
#include <stdio.h>
main() {
int H, W, a, b;
while (1) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0) {
break;
}
for (a = 1; a <= H; a++) {
for (b = 1; b <= W; b++) {
if (a % 2 == 1) {
if (b % 2 == 1)
printf("#");
else
printf(".");
... | #include <stdio.h>
main() {
int H, W, a, b;
while (1) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0) {
break;
}
for (a = 1; a <= H; a++) {
for (b = 1; b <= W; b++) {
if (a % 2 == 1) {
if (b % 2 == 1)
printf("#");
else
printf(".");
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 0, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 149 |
#include <stdio.h>
int main(void) {
int a, b, c, d, e, f;
while (1) {
scanf("%d %d", &a, &b);
if (a == 0 && b == 0)
break;
for (c = 0; c < a; c++) {
for (d = 0; d < b; d++) {
if (c % 2 == 0) {
e = d % 2;
if (e == 0) {
printf("#");
} else {
... | #include <stdio.h>
int main(void) {
int a, b, c, d, e, f;
while (1) {
scanf("%d %d", &a, &b);
if (a == 0 && b == 0)
break;
for (c = 0; c < a; c++) {
for (d = 0; d < b; d++) {
if (c % 2 == 0) {
e = d % 2;
if (e == 0) {
printf("#");
} else {
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 168 |
#include <stdio.h>
int main(void) {
int i, j, H, W;
while (1) {
scanf("%d", &H);
scanf("%d", &W);
if (W == 0 && H == 0)
break;
for (i = 0; i < H; i++) {
for (j = 0; j < W; j++) {
if ((i + j) % 2 == 0)
printf("#");
else
printf(".");
}
prin... | #include <stdio.h>
int main(void) {
int i, j, H, W;
while (1) {
scanf("%d", &H);
scanf("%d", &W);
if (W == 0 && H == 0)
break;
for (i = 0; i < H; i++) {
for (j = 0; j < W; j++) {
if ((i + j) % 2 == 0)
printf("#");
else
printf(".");
}
prin... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 123 |
#include <stdio.h>
int main(void) {
int i, k, h, w;
while (1) {
scanf("%d %d", &h, &w);
if (h == 0 && w == 0)
break;
for (i = 0; i < h; i++) {
for (k = 0; k < w; k++) {
if (i % 2 == 0) {
if (k % 2 == 0)
printf("#");
else
printf(".");
... | #include <stdio.h>
int main(void) {
int i, k, h, w;
while (1) {
scanf("%d %d", &h, &w);
if (h == 0 && w == 0)
break;
for (i = 0; i < h; i++) {
for (k = 0; k < w; k++) {
if (i % 2 == 0) {
if (k % 2 == 0)
printf("#");
else
printf(".");
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 148 |
#include <stdio.h>
int main(void) {
int H, W;
int i, j;
while (1) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0) {
break;
}
for (i = 0; i < H; i++) {
for (j = 0; j < W; j++) {
if (i % 2 == 0) {
if (j % 2 == 0) {
putchar('#');
} else {
... | #include <stdio.h>
int main(void) {
int H, W;
int i, j;
while (1) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0) {
break;
}
for (i = 0; i < H; i++) {
for (j = 0; j < W; j++) {
if (i % 2 == 0) {
if (j % 2 == 0) {
putchar('#');
} else {
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 103, 0, 104], ["+", 0, 1, 0, 2, 3, 4, 0, 103, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 159 |
#include <stdio.h>
int main() {
int i, j, h, w;
while (1) {
scanf("%d %d", &h, &w);
if (h == 0 && w == 0) {
break;
}
for (i = 0; i < h; i++) {
for (j = 0; j < w; j++) {
if (((i + j) % 2) == 0) {
printf("#");
} else {
printf(".");
}
}
... | #include <stdio.h>
int main() {
int i, j, h, w;
while (1) {
scanf("%d %d", &h, &w);
if (h == 0 && w == 0) {
break;
}
for (i = 0; i < h; i++) {
for (j = 0; j < w; j++) {
if (((i + j) % 2) == 0) {
printf("#");
} else {
printf(".");
}
}
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 123 |
#include <stdio.h>
int main() {
int H, W, i, j;
while (1) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0)
break;
for (i = 0; i < H; i++) {
for (j = 0; j < W; j++) {
if ((j + i) % 2 == 0) {
printf("#");
} else {
printf(".");
}
}
print... | #include <stdio.h>
int main() {
int H, W, i, j;
while (1) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0)
break;
for (i = 0; i < H; i++) {
for (j = 0; j < W; j++) {
if ((j + i) % 2 == 0) {
printf("#");
} else {
printf(".");
}
}
print... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 119 |
#include <stdio.h>
int main(void) {
int H, W, i, a;
while (1) {
scanf("%d%d", &H, &W);
if (H == 0 && W == 0) {
break;
}
for (i = 0; i < H; i++) {
if (i % 2 == 0) {
for (a = 0; a < W; a++) {
if (a % 2 == 0) {
printf("#");
} else {
prin... | #include <stdio.h>
int main(void) {
int H, W, i, a;
while (1) {
scanf("%d%d", &H, &W);
if (H == 0 && W == 0) {
break;
}
for (i = 0; i < H; i++) {
if (i % 2 == 0) {
for (a = 0; a < W; a++) {
if (a % 2 == 0) {
printf("#");
} else {
prin... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 173 |
#include <stdio.h>
int main() {
int h, w;
int i, t;
while (1) {
scanf("%d %d", &h, &w);
if (h == 0 && w == 0)
break;
for (i = 0; i < h; i++) {
for (t = 0; t < w; t++) {
if ((i + t) % 2)
printf("#");
else
printf(".");
}
puts("");
}
pu... | #include <stdio.h>
int main() {
int h, w;
int i, t;
while (1) {
scanf("%d %d", &h, &w);
if (h == 0 && w == 0)
break;
for (i = 0; i < h; i++) {
for (t = 0; t < w; t++) {
if ((i + t) % 2)
printf(".");
else
printf("#");
}
puts("");
}
pu... | [["-", 64, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 64, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["-", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6]] | 0 | 119 |
#include <stdio.h>
int main() {
int j, i = 1, H[10000], W[10000], a = -1, k, l, m;
while (i == 1) {
a++;
scanf("%d %d", &H[a], &W[a]);
if (H[a] == 0 && W[a] == 0)
i = 0;
}
for (j = 0; j < a; j++) {
for (m = 0; m < H[j]; m++) {
if (m % 2 == 0) {
for (k = 0; k < W[j]; k++) ... | #include <stdio.h>
int main() {
int j, i = 1, H[10000], W[10000], a = -1, k, l, m;
while (i == 1) {
a++;
scanf("%d %d", &H[a], &W[a]);
if (H[a] == 0 && W[a] == 0)
i = 0;
}
for (j = 0; j < a; j++) {
for (m = 0; m < H[j]; m++) {
if (m % 2 == 0) {
for (k = 0; k < W[j]; k++) ... | [["+", 0, 7, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 7, 8, 9, 0, 1, 0, 35]] | 0 | 259 |
#include <stdio.h>
void White(int W) {
int j;
for (j = 0; j < W; j++) {
if (j % 2 == 0)
putchar('#');
if (j % 2 == 1)
putchar('.');
}
}
void Black(int W) {
int j;
for (j = 0; j < W; j++) {
if (j % 2 == 0)
putchar('.');
if (j % 2 == 1)
putchar('#');
}
}
void printin... | #include <stdio.h>
void White(int W) {
int j;
for (j = 0; j < W; j++) {
if (j % 2 == 0)
putchar('#');
if (j % 2 == 1)
putchar('.');
}
}
void Black(int W) {
int j;
for (j = 0; j < W; j++) {
if (j % 2 == 0)
putchar('.');
if (j % 2 == 1)
putchar('#');
}
}
void printin... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 266 |
#include <stdio.h>
int i, j, k, H, W;
void Drawline_0(int W) {
for (j = 0; j < W; j++) {
if (j % 2 == 0) {
printf("#");
} else {
printf(".");
}
}
printf("\n");
}
void Drawline_1(int W) {
for (j = 0; j < W; j++) {
if (j % 2 == 1) {
printf("#");
} else {
printf(".");... | #include <stdio.h>
int i, j, k, H, W;
void Drawline_0(int W) {
for (j = 0; j < W; j++) {
if (j % 2 == 0) {
printf("#");
} else {
printf(".");
}
}
printf("\n");
}
void Drawline_1(int W) {
for (j = 0; j < W; j++) {
if (j % 2 == 1) {
printf("#");
} else {
printf(".");... | [["+", 0, 7, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 7, 8, 9, 0, 1, 0, 35]] | 0 | 215 |
#include <math.h>
#include <stdio.h>
int main(void) {
int h, w, i, j;
while (scanf("%d %d", &h, &w) != EOF) {
;
if (h == 0 && w == 0)
break;
for (i = 0; i < h; i++) {
for (j = 0; j < w; j++)
printf("%c", (i + j) % 2 == 0 ? '#' : '.');
printf("\n");
}
}
return 0;
} | #include <math.h>
#include <stdio.h>
int main(void) {
int h, w, i, j;
while (scanf("%d %d", &h, &w) != EOF) {
;
if (h == 0 && w == 0)
break;
for (i = 0; i < h; i++) {
for (j = 0; j < w; j++)
printf("%c", (i + j) % 2 == 0 ? '#' : '.');
printf("\n");
}
printf("\n");
}
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 115 |
#include <stdio.h>
int main(void) {
int H, W, i, j;
while (1) {
scanf("%d %d", &H, &W);
if (H == 0 & W == 0)
break;
for (i = 0; i < H; i++) {
if (i % 2 == 0) {
for (j = 0; j < W; j++) {
if (j % 2 == 0) {
printf("#");
} else {
printf(".");
... | #include <stdio.h>
int main(void) {
int H, W, i, j;
while (1) {
scanf("%d %d", &H, &W);
if (H == 0 & W == 0)
break;
for (i = 0; i < H; i++) {
if (i % 2 == 0) {
for (j = 0; j < W; j++) {
if (j % 2 == 0) {
printf("#");
} else {
printf(".");
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 171 |
#include <stdio.h>
int main(void) {
int h, w, a, b;
while (1) {
scanf("%d %d", &h, &w);
if (h == 0)
if (w == 0) {
break;
}
for (a = 0; a < h; a++) {
for (b = 0; b < w; b++) {
if ((a + b) % 2 == 1)
printf("#");
else
printf(".");
}
... | #include <stdio.h>
int main(void) {
int h, w, a, b;
while (1) {
scanf("%d %d", &h, &w);
if (h == 0)
if (w == 0) {
break;
}
for (a = 0; a < h; a++) {
for (b = 0; b < w; b++) {
if ((a + b) % 2 == 1)
printf(".");
else
printf("#");
}
... | [["-", 64, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 64, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["-", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6]] | 0 | 127 |
#include <stdio.h>
int main(void) {
int a, b, H, W;
while (1) {
scanf("%d %d", &H, &W);
if ((H == 0) && (W == 0)) {
break;
} else {
for (a = 1; a <= H; a++) {
for (b = 1; b <= W; b++) {
if (a % 2 == 0) {
if (b % 2 == 0) {
printf("#");
... | #include <stdio.h>
int main(void) {
int a, b, H, W;
while (1) {
scanf("%d %d", &H, &W);
if ((H == 0) && (W == 0)) {
break;
} else {
for (a = 1; a <= H; a++) {
for (b = 1; b <= W; b++) {
if (a % 2 == 0) {
if (b % 2 == 0) {
printf("#");
... | [["+", 75, 76, 0, 9, 0, 1, 0, 2, 63, 22], ["+", 0, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 0, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 0, 57, 75, 76, 0, 9, 0, 1, 0, 35]] | 0 | 165 |
#include <stdio.h>
int main(void) {
int h, w;
int i, j;
while (1) {
scanf("%d %d", &h, &w);
if (h + w == 0)
break;
for (i = 0; i < h; i++) {
for (j = 0; j < w; j++) {
if ((j + i) % 2 == 0)
putchar('#');
else
putchar('.');
}
puts("");
}
... | #include <stdio.h>
int main(void) {
int h, w;
int i, j;
while (1) {
scanf("%d %d", &h, &w);
if (h + w == 0)
break;
for (i = 0; i < h; i++) {
for (j = 0; j < w; j++) {
if ((j + i) % 2 == 0)
putchar('#');
else
putchar('.');
}
puts("");
}
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 114 |
//??°??????????????°??????
int main() {
int h, w, i, x, y, z;
for (z = 0; 1; z++) {
scanf("%d%d", &h, &w);
if (w == 0 && h == 0)
break;
for (y = 0; y < h; y++) {
if (y % 2 == 0) {
for (x = 0; 1; x++) {
if (i < w) {
printf("#");
i = i + 1;
... | int main() {
int h, w, i, x, y, z;
for (z = 0; 1; z++) {
scanf("%d%d", &h, &w);
if (w == 0 && h == 0)
break;
for (y = 0; y < h; y++) {
if (y % 2 == 0) {
for (x = 0; 1; x++) {
if (i < w) {
printf("#");
i = i + 1;
}
if (i < w) {
... | [["+", 0, 7, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 7, 8, 9, 0, 1, 0, 35]] | 0 | 233 |
#include <stdio.h>
int main(void) {
int H, W, i, j;
while (1) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0)
return 0;
for (i = 1; i <= H; i++) {
for (j = 1; j <= W; j++) {
if ((i + j) % 2 == 0)
printf("#");
else
printf(".");
}
printf("\n");... | #include <stdio.h>
int main(void) {
int H, W, i, j;
while (1) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0)
return 0;
for (i = 1; i <= H; i++) {
for (j = 1; j <= W; j++) {
if ((i + j) % 2 == 0)
printf("#");
else
printf(".");
}
printf("\n");
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 114 |
#include <stdio.h>
int main() {
int w, h;
int i, j;
while (1) {
scanf("%d %d", &h, &w);
if (w == 0 && h == 0) {
break;
}
for (i = 1; i <= h; i++) {
for (j = 1; j <= w; j++) {
if ((i + j) % 2 == 1) {
printf(".");
}
if ((i + j) % 2 == 0) {
... | #include <stdio.h>
int main() {
int w, h;
int i, j;
while (1) {
scanf("%d %d", &h, &w);
if (w == 0 && h == 0) {
break;
}
for (i = 1; i <= h; i++) {
for (j = 1; j <= w; j++) {
if ((i + j) % 2 == 1) {
printf(".");
}
if ((i + j) % 2 == 0) {
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 135 |
#include <stdio.h>
int main() {
int H, W, a[300], b[300], i = 0, N = 0;
scanf("%d %d", &a[0], &b[0]);
while (a[i] != 0 || b[i] != 0) {
N++;
i++;
scanf("%d %d", &a[i], &b[i]);
}
for (i = 0; i <= N - 1; i++) {
for (H = 1; H <= a[i]; H++) {
if (H % 2 == 1) {
if (b[i] % 2 == 0) {
... | #include <stdio.h>
int main() {
int H, W, a[300], b[300], i = 0, N = 0;
scanf("%d %d", &a[0], &b[0]);
while (a[i] != 0 || b[i] != 0) {
N++;
i++;
scanf("%d %d", &a[i], &b[i]);
}
for (i = 0; i <= N - 1; i++) {
for (H = 1; H <= a[i]; H++) {
if (H % 2 == 1) {
if (b[i] % 2 == 0) {
... | [["+", 0, 7, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 7, 8, 9, 0, 1, 0, 35]] | 0 | 336 |
#include <stdio.h>
int main(void) {
int h, w, hc, wc, c, d;
while (1) {
scanf("%d %d", &h, &w);
if (h == 0 && w == 0) {
break;
}
c = 0;
d = 0;
for (hc = 1; hc <= h; hc++) {
for (wc = 1; wc <= w; wc++) {
if (c == 0) {
printf("#");
c = 1;
} else ... | #include <stdio.h>
int main(void) {
int h, w, hc, wc, c, d;
while (1) {
scanf("%d %d", &h, &w);
if (h == 0 && w == 0) {
break;
}
c = 0;
d = 0;
for (hc = 1; hc <= h; hc++) {
for (wc = 1; wc <= w; wc++) {
if (c == 0) {
printf("#");
c = 1;
} else ... | [["+", 0, 7, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 7, 8, 9, 0, 1, 0, 35]] | 0 | 163 |
#include <stdio.h>
int main() {
int i, j, a, b;
while (1) {
scanf("%d%d", &a, &b);
if (a == 0 && b == 0)
break;
for (i = 1; i <= a; i++) {
for (j = 1; j <= b; j++) {
if (i % 2 != 0) {
if (j % 2 != 0)
printf("#");
else
printf(".");
... | #include <stdio.h>
int main() {
int i, j, a, b;
while (1) {
scanf("%d%d", &a, &b);
if (a == 0 && b == 0)
break;
for (i = 1; i <= a; i++) {
for (j = 1; j <= b; j++) {
if (i % 2 != 0) {
if (j % 2 != 0)
printf("#");
else
printf(".");
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 155 |
#include <stdio.h>
int main(void) {
int i, j, H, W;
while (scanf("%d %d", &H, &W) != EOF) {
if (H == 0 && W == 0) {
break;
}
for (i = 0; i < H; i++) {
for (j = 0; j < W; j++) {
if ((j % 2 == 1 && i % 2 == 1) || (j % 2 == 0 && i % 2 == 0)) {
printf("#");
} else if ((... | #include <stdio.h>
int main(void) {
int i, j, H, W;
while (scanf("%d %d", &H, &W) != EOF) {
if (H == 0 && W == 0) {
break;
}
for (i = 0; i < H; i++) {
for (j = 0; j < W; j++) {
if ((j % 2 == 1 && i % 2 == 1) || (j % 2 == 0 && i % 2 == 0)) {
printf("#");
} else if ((... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 0 | 172 |
#include <stdio.h>
int main() {
int a, b;
while (1) {
scanf("%d", &a);
if (a == 0)
break;
scanf("%d", &b);
for (int i = 1; i <= a; i++) {
for (int h = 1; h <= b; h++) {
if (i % 2 == 1) {
if (h % 2 == 1)
printf("#");
else
printf(".");
... | #include <stdio.h>
int main() {
int a, b;
while (1) {
scanf("%d", &a);
if (a == 0)
break;
scanf("%d", &b);
for (int i = 1; i <= a; i++) {
for (int h = 1; h <= b; h++) {
if (i % 2 == 1) {
if (h % 2 == 1)
printf("#");
else
printf(".");
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 1 | 155 |
#include <stdio.h>
int main() {
int i, k, length, width;
while (1) {
scanf("%d %d", &length, &width);
if (length == 0 && width == 0) {
break;
}
for (i = 1; i <= length; i++) {
if (i % 2 == 1) {
for (k = 1; k <= width; k++) {
if (k % 2 == 1) {
printf("#");
... | #include <stdio.h>
int main() {
int i, k, length, width;
while (1) {
scanf("%d %d", &length, &width);
if (length == 0 && width == 0) {
break;
}
for (i = 1; i <= length; i++) {
if (i % 2 == 1) {
for (k = 1; k <= width; k++) {
if (k % 2 == 1) {
printf("#");
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 1 | 179 |
#include <iostream>
int main() {
int h, w;
while (1) {
std::cin >> h >> w;
if (!h && !w)
break;
for (int j = 0; j < h; j++) {
for (int i = 0; i < w; i++) {
if ((i - j) % 2)
std::cout << '#';
else
std::cout << '.';
}
std::cout << std::endl;
... | #include <iostream>
int main() {
int h, w;
while (1) {
std::cin >> h >> w;
if (!h && !w)
break;
for (int j = 0; j < h; j++) {
for (int i = 0; i < w; i++) {
if ((i - j) % 2)
std::cout << '.';
else
std::cout << '#';
}
std::cout << std::endl;
... | [["-", 0, 57, 64, 1, 0, 16, 12, 103, 0, 125], ["+", 0, 57, 64, 1, 0, 16, 12, 103, 0, 125], ["-", 75, 76, 0, 1, 0, 16, 12, 103, 0, 125], ["+", 75, 76, 0, 1, 0, 16, 12, 103, 0, 125]] | 1 | 115 |
#include <iostream>
using namespace std;
int main() {
int W, H;
while (1) {
cin >> H >> W;
if ((H == 0) && (W == 0))
break;
for (int i = 0; i < H; i++) {
for (int j = 0; j < W; j++) {
if ((i % 2) == 0) {
if ((j % 2) == 0) {
cout << '#';
} else {... | #include <iostream>
using namespace std;
int main() {
int W, H;
while (1) {
cin >> H >> W;
if ((H == 0) && (W == 0))
break;
for (int i = 0; i < H; i++) {
for (int j = 0; j < W; j++) {
if ((i % 2) == 0) {
if ((j % 2) == 0) {
cout << '#';
} else {
... | [["+", 0, 52, 8, 9, 0, 1, 0, 16, 31, 22], ["+", 0, 52, 8, 9, 0, 1, 0, 16, 17, 151], ["+", 8, 9, 0, 1, 0, 16, 12, 5, 0, 62], ["+", 8, 9, 0, 1, 0, 16, 12, 5, 0, 44], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 1 | 155 |
#include <stdio.h>
int main(void) {
int H, W;
while (1) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0) {
break;
} else {
for (int i = 0; i < H; i++) {
for (int j = 0; j < W; j++) {
if ((i % 2 == 0 && j % 2 != 0) || (i % 2 != 0 && j % 2 == 0))
printf("#");
... | #include <stdio.h>
int main(void) {
int H, W;
while (1) {
scanf("%d %d", &H, &W);
if (H == 0 && W == 0) {
break;
} else {
for (int i = 0; i < H; i++) {
for (int j = 0; j < W; j++) {
if ((i % 2 == 0 && j % 2 != 0) || (i % 2 != 0 && j % 2 == 0))
printf(".");
... | [["-", 64, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 64, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["-", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6]] | 1 | 144 |
#include <stdio.h>
int main(void) {
int w, h;
scanf("%d %d", &h, &w);
while (w != 0 || h != 0) {
for (int i = 0; i < h; i++) {
for (int j = 0; j < w; j++) {
if ((i + j) % 2 == 0)
printf(".");
else
printf("#");
}
printf("\n");
}
printf("\n");
... | #include <stdio.h>
int main(void) {
int w, h;
scanf("%d %d", &h, &w);
while (w != 0 || h != 0) {
for (int i = 0; i < h; i++) {
for (int j = 0; j < w; j++) {
if ((i + j) % 2 == 0)
printf("#");
else
printf(".");
}
printf("\n");
}
printf("\n");
... | [["-", 64, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 64, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["-", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6]] | 1 | 128 |
#include <cstdio>
using namespace std;
int main(void) {
int i, j, h, w, flg, k;
scanf("%d %d", &h, &w);
while (!(h == 0 && w == 0)) {
for (i = 0; i < h; i++) {
for (j = 0; j < w; j++) {
if ((i + j) % 2 == 1)
printf(".");
else
printf("#");
}
printf("\n");
... | #include <cstdio>
using namespace std;
int main(void) {
int i, j, h, w, flg, k;
scanf("%d %d", &h, &w);
while (!(h == 0 && w == 0)) {
for (i = 0; i < h; i++) {
for (j = 0; j < w; j++) {
if ((i + j) % 2 == 1)
printf(".");
else
printf("#");
}
printf("\n");
... | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 44], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 1 | 134 |
#include <iostream>
using namespace std;
int main(void) {
int w, h;
while (1) {
cin >> h >> w;
if (w == 0 && h == 0) {
break;
}
for (int i = 0; i < h; ++i) {
for (int j = 0; j < w; ++j) {
if (j % 2 == 0 && i % 2 == 0 || j % 2 == 1 && i % 2 == 1) {
cout << "#";
... | #include <iostream>
using namespace std;
int main(void) {
int w, h;
while (1) {
cin >> h >> w;
if (w == 0 && h == 0) {
break;
}
for (int i = 0; i < h; ++i) {
for (int j = 0; j < w; ++j) {
if (j % 2 == 0 && i % 2 == 0 || j % 2 == 1 && i % 2 == 1) {
cout << "#";
... | [["+", 0, 52, 8, 9, 0, 1, 0, 16, 31, 22], ["+", 0, 52, 8, 9, 0, 1, 0, 16, 17, 151], ["+", 8, 9, 0, 1, 0, 16, 12, 5, 0, 62], ["+", 8, 9, 0, 1, 0, 16, 12, 5, 0, 44], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 1 | 128 |
#include <iostream>
using namespace std;
int main() {
int h, w;
while (1) {
cin >> h >> w;
if (h == 0 && w == 0) {
break;
}
for (int i = 0; i < h; i++) {
for (int j = 0; j < w; j++) {
if (i % 2 == 0) {
if (j % 2 == 0)
cout << '#';
else
... | #include <iostream>
using namespace std;
int main() {
int h, w;
while (1) {
cin >> h >> w;
if (h == 0 && w == 0) {
break;
}
for (int i = 0; i < h; i++) {
for (int j = 0; j < w; j++) {
if (i % 2 == 0) {
if (j % 2 == 0)
cout << '#';
else
... | [["-", 0, 7, 8, 9, 0, 1, 0, 16, 31, 22], ["-", 0, 7, 8, 9, 0, 1, 0, 16, 17, 151], ["-", 8, 9, 0, 1, 0, 16, 12, 103, 0, 104], ["-", 8, 9, 0, 1, 0, 16, 12, 103, 0, 125], ["-", 8, 9, 0, 7, 8, 9, 0, 1, 0, 35]] | 1 | 151 |
#include <iostream>
using namespace std;
int main() {
int H = 0;
int W = 0;
int i;
int j;
while (1) {
cin >> H >> W;
if (H == 0 && W == 0)
goto EXIT;
/* for(i=0;i<H;i++)
{
switch(a)
{
case 0:check=0; a=1; break;
case 1:check=1; a=0; break;
}
... | #include <iostream>
using namespace std;
int main() {
int H = 0;
int W = 0;
int i;
int j;
while (1) {
cin >> H >> W;
if (H == 0 && W == 0)
goto EXIT;
/* for(i=0;i<H;i++)
{
switch(a)
{
case 0:check=0; a=1; break;
case 1:check=1; a=0; break;
}
... | [["+", 0, 52, 8, 9, 0, 1, 0, 16, 31, 22], ["+", 0, 52, 8, 9, 0, 1, 0, 16, 17, 151], ["+", 8, 9, 0, 1, 0, 16, 12, 5, 0, 62], ["+", 8, 9, 0, 1, 0, 16, 12, 5, 0, 44], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 1 | 173 |
#include <iostream>
using namespace std;
int main() {
cin.tie(0);
ios::sync_with_stdio(false);
int H, W;
while (cin >> H >> W && (H > 0 || W > 0)) {
for (int i = 0; i < H; i++) {
for (int j = 0; j < W; j++) {
if ((i + j) % 2 == 0)
cout << ".";
else
cout << "#";
... | #include <iostream>
using namespace std;
int main() {
cin.tie(0);
ios::sync_with_stdio(false);
int H, W;
while (cin >> H >> W && (H > 0 || W > 0)) {
for (int i = 0; i < H; i++) {
for (int j = 0; j < W; j++) {
if ((i + j) % 2 == 0)
cout << "#";
else
cout << ".";
... | [["-", 0, 57, 64, 1, 0, 16, 12, 5, 0, 6], ["+", 0, 57, 64, 1, 0, 16, 12, 5, 0, 6], ["-", 75, 76, 0, 1, 0, 16, 12, 5, 0, 6], ["+", 75, 76, 0, 1, 0, 16, 12, 5, 0, 6]] | 1 | 120 |
a="#"
b="."
loop{
h,w=gets.split(" ").map(&:to_i)
break if h==0 and w==0
h.times{|a|
w.times{|i|
if (a+i)%2==0
print("#{a}")
else
print("#{b}")
end
}
puts""
}
puts""
}
| a="#"
b="."
loop{
h,w=gets.split(" ").map(&:to_i)
break if h==0 and w==0
h.times{|i|
w.times{|j|
if (i+j)%2==0
print("#{a}")
else
print("#{b}")
end
}
puts""
}
puts""
}
| [["-", 8, 734, 0, 652, 196, 196, 54, 758, 0, 22], ["+", 8, 734, 0, 652, 196, 196, 54, 758, 0, 22], ["-", 15, 738, 31, 738, 31, 739, 0, 738, 31, 22], ["-", 15, 738, 31, 738, 31, 739, 0, 738, 17, 72], ["+", 15, 738, 31, 738, 31, 739, 0, 738, 17, 72], ["+", 15, 738, 31, 738, 31, 739, 0, 738, 12, 22]] | 4 | 90 |
loop do
h, w = gets.chomp.split.map(&:to_i)
break if h == 0 && w == 0
h.times do
print("#"*w, "\n")
end
end | loop do
h, w = gets.chomp.split.map(&:to_i)
break if h == 0 && w == 0
h.times do |i|
print("#"*w, "\n")
end
puts "\n"
end | [["+", 8, 736, 0, 652, 196, 737, 54, 758, 0, 139], ["+", 8, 736, 0, 652, 196, 737, 54, 758, 0, 22], ["+", 0, 652, 196, 737, 8, 736, 0, 652, 735, 22], ["+", 8, 736, 0, 652, 3, 4, 0, 557, 0, 62], ["+", 8, 736, 0, 652, 3, 4, 0, 557, 0, 44]] | 4 | 44 |
while str = STDIN.gets
n = str.split(" ")
a = n[0].to_i
b = n[1].to_i
if a == 0 || b == 0
break
end
for h in 1..a do
for w in 1..b do
print "#"
end
print "\n"
end
end
| while str = STDIN.gets
n = str.split(" ")
a = n[0].to_i
b = n[1].to_i
if a == 0 && b == 0
break
else
for h in 1..a do
for w in 1..b do
print "#"
end
print "\n"
end
end
print "\n"
end
| [["-", 0, 89, 8, 170, 0, 121, 15, 738, 17, 106], ["+", 0, 89, 8, 170, 0, 121, 15, 738, 17, 98], ["-", 0, 493, 0, 89, 8, 170, 0, 121, 0, 444], ["+", 0, 89, 8, 170, 0, 121, 75, 95, 0, 95], ["+", 0, 493, 0, 89, 8, 170, 0, 121, 0, 444], ["+", 0, 493, 0, 89, 8, 170, 0, 652, 735, 22], ["+", 8, 170, 0, 652, 3, 4, 0, 557, 0, 6... | 4 | 67 |
while True:
H,W = map(int, input().split())
if H==0 and W==0: break
for y in range(0,H):
for x in range(0,W):
print("#",end="")
print('\n')
print('\n')
| while True:
H,W = map(int, input().split())
if H==0 and W==0: break
for y in range(0,H):
for x in range(0,W):
print("#",end="")
print()
print()
| [["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 654], ["-", 0, 652, 3, 4, 0, 557, 0, 6, 0, 44], ["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 655]] | 5 | 72 |
while True:
num = list(map(int,input().split()))
if(num[0] == 0 and num[1] == 0):break
else:
for i in range(num[0]):
for j in range(num[1]):
print("#",end="")
print("\n")
| while True:
num = list(map(int,input().split()))
if(num[0] == 0 and num[1] == 0):break
else:
for i in range(num[0]):
for j in range(num[1]):
print("#",end="")
print("")
print("")
| [["-", 0, 652, 3, 4, 0, 557, 0, 6, 0, 44], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 655], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 25], ["+", 75, 76, 8, 196, 0, 1, 0, 652, 63, 22], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 24], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 654]] | 5 | 79 |
while True:
H,W = list(map(int, input().split()))
if (H == 0) and (W == 0):
break
else:
for n in range(0, H):
s = ""
for m in range(0, W):
s += "#"
print(s) | while True:
H,W = list(map(int, input().split()))
if (H == 0 and W == 0):
break
else:
for n in range(0, H):
s = ""
for m in range(0, W):
s += "#"
print(s)
print("") | [["-", 8, 196, 0, 57, 15, 679, 31, 23, 0, 25], ["-", 8, 196, 0, 57, 15, 679, 12, 23, 0, 24], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 25], ["+", 75, 76, 8, 196, 0, 1, 0, 652, 63, 22], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 24], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 654], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 655]] | 5 | 71 |
while True:
h, w = list(map(int, input().stlip()))
if h == 0 and w == 0:
break
for i in range(h):
print("#" * w) | while True:
h, w = list(map(int, input().split()))
if h == 0 and w == 0:
break
for i in range(h):
print("#" * w)
print("") | [["-", 0, 652, 3, 4, 0, 652, 63, 319, 319, 22], ["+", 0, 652, 3, 4, 0, 652, 63, 319, 319, 22], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 25], ["+", 0, 52, 8, 196, 0, 1, 0, 652, 63, 22], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 24], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 654], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 655]] | 5 | 48 |
while True:
H, W = list(map(int, input().split()))
if H == 0 and W == 0:
break
for i in range(0, H):
print('#'*W)
print('\n') | while True:
H, W = list(map(int, input().split()))
if H == 0 and W == 0:
break
for i in range(H):
print("#"*W)
print("") | [["-", 8, 196, 0, 7, 12, 652, 3, 4, 0, 612], ["-", 8, 196, 0, 7, 12, 652, 3, 4, 0, 21], ["-", 0, 652, 3, 4, 0, 657, 31, 557, 0, 654], ["+", 0, 652, 3, 4, 0, 657, 31, 557, 0, 654], ["-", 0, 652, 3, 4, 0, 657, 31, 557, 0, 655], ["+", 0, 652, 3, 4, 0, 657, 31, 557, 0, 655], ["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 654], ["-",... | 5 | 56 |
while True:
h,w = list(map(int,input().split()))
if h == 0 and w == 0:
break
for number in range(h):
print("#"*w /n) | while True:
h,w = list(map(int,input().split()))
if h == 0 and w == 0:
break
for number in range(h):
print("#"*w)
print("") | [["-", 0, 1, 0, 652, 3, 4, 0, 657, 17, 85], ["-", 0, 1, 0, 652, 3, 4, 0, 657, 12, 22], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 25], ["+", 0, 52, 8, 196, 0, 1, 0, 652, 63, 22], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 24], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 654], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 655]] | 5 | 50 |
while True:
H,W = map(int, input().split())
if H == 0 and W == 0:
break
for i in range(H):
print (("#" * W ) + "\n\n") | while True:
H,W = map(int, input().split())
if H == 0 and W == 0:
break
for i in range(H):
print (("#" * W ))
print () | [["-", 0, 1, 0, 652, 3, 4, 0, 657, 17, 72], ["-", 0, 652, 3, 4, 0, 657, 12, 557, 0, 654], ["-", 3, 4, 0, 657, 12, 557, 0, 6, 0, 44], ["-", 0, 652, 3, 4, 0, 657, 12, 557, 0, 655], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 25], ["+", 0, 52, 8, 196, 0, 1, 0, 652, 63, 22], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 24]] | 5 | 52 |
#include <bits/stdc++.h>
using namespace std;
int main() {
while (1) {
int h, w, i, j;
cin >> h >> w;
if (h == 0 && w == 0)
return 0;
for (i = 0; i < h; i++) {
if (i % 2 == 0) {
for (j = 0; j < w; j++) {
cout << "#";
j++;
if (j == w)
break;... | #include <bits/stdc++.h>
using namespace std;
int main() {
while (1) {
int h, w, i, j;
cin >> h >> w;
if (h == 0 && w == 0)
return 0;
for (i = 0; i < h; i++) {
if (i % 2 == 0) {
for (j = 0; j < w; j++) {
cout << "#";
j++;
if (j == w)
break;... | [["+", 0, 52, 8, 9, 0, 1, 0, 16, 31, 22], ["+", 0, 52, 8, 9, 0, 1, 0, 16, 17, 151], ["+", 8, 9, 0, 1, 0, 16, 12, 5, 0, 62], ["+", 8, 9, 0, 1, 0, 16, 12, 5, 0, 44], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 1 | 165 |
#include <stdio.h>
int main() {
int n, m;
while (scanf("%d %d", &n, &m), n + m) {
for (int i = 0; i < n; i++) {
for (int j = 0; j < m; j++)
if ((i + j) % 2 == 0)
putchar('#');
else
putchar('.');
puts("");
}
}
return 0;
} | #include <stdio.h>
int main() {
int n, m;
while (scanf("%d %d", &n, &m), n + m) {
for (int i = 0; i < n; i++) {
for (int j = 0; j < m; j++)
if ((i + j) % 2 == 0)
putchar('#');
else
putchar('.');
puts("");
}
puts("");
}
return 0;
} | [["+", 0, 52, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 62], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 9, 0, 52, 8, 9, 0, 1, 0, 35]] | 1 | 100 |
#include <bits/stdc++.h>
int main() {
int h, w;
int start = 1;
while (1) {
scanf("%d %d", &h, &w);
if (start)
start = 0;
else
putchar('\n');
if (h == 0 && w == 0)
break;
for (int i = 0; i < h; i++) {
for (int j = 0; j < w; j++)
if ((i + j) % 2)
putcha... | #include <bits/stdc++.h>
int main() {
int h, w;
int start = 1;
while (1) {
scanf("%d %d", &h, &w);
if (start)
start = 0;
else
putchar('\n');
if (h == 0 && w == 0)
break;
for (int i = 0; i < h; i++) {
for (int j = 0; j < w; j++)
if ((i + j) % 2)
putcha... | [["-", 64, 1, 0, 2, 3, 4, 0, 103, 0, 125], ["+", 64, 1, 0, 2, 3, 4, 0, 103, 0, 125], ["-", 0, 1, 0, 2, 3, 4, 0, 103, 0, 125], ["+", 0, 1, 0, 2, 3, 4, 0, 103, 0, 125]] | 1 | 130 |
#include <bits/stdc++.h>
using namespace std;
int main() {
while (true) {
int h, w;
cin >> h >> w;
if (h == 0 && w == 0)
break;
for (int i = 0; i < h; i++) {
for (int j = 0; j < w; j++)
if ((i ^ j) & 1)
cout << '#';
else
cout << '.';
cout << endl;
... | #include <bits/stdc++.h>
using namespace std;
int main() {
while (true) {
int h, w;
cin >> h >> w;
if (h == 0 && w == 0)
break;
for (int i = 0; i < h; i++) {
for (int j = 0; j < w; j++)
if ((i ^ j) & 1)
cout << '.';
else
cout << '#';
cout << endl;
... | [["-", 8, 57, 64, 1, 0, 16, 12, 103, 0, 125], ["+", 8, 57, 64, 1, 0, 16, 12, 103, 0, 125], ["-", 75, 76, 0, 1, 0, 16, 12, 103, 0, 125], ["+", 75, 76, 0, 1, 0, 16, 12, 103, 0, 125]] | 1 | 102 |
while(True):
H, W = map(int, input().split())
if(H == 0 and W == 0):
break
else:
fir = "#"
sec = "."
for i in range(H):
for k in range(W):
if k%2:
print(fir, end = "")
else:
print(sec, end = "... | while(True):
H, W = map(int, input().split())
if(H == 0 and W == 0):
break
else:
fir = "#"
sec = "."
for i in range(H):
for k in range(W):
if k%2:
print(sec, end = "")
else:
print(fir, end = "... | [["-", 64, 196, 0, 1, 0, 652, 3, 4, 0, 22], ["+", 64, 196, 0, 1, 0, 652, 3, 4, 0, 22], ["-", 8, 196, 0, 1, 0, 652, 3, 4, 0, 22], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 22], ["+", 0, 7, 8, 196, 0, 1, 0, 652, 63, 22], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 24], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 654], ["+", 0, 1, 0, 652, 3... | 5 | 100 |
while 1:
H, W = map(int, input().split())
if H == 0 and W == 0:
break
for i in range(0, H):
line = '#' * W + ' '
print(line) | while 1:
H, W = map(int, input().split())
if H == 0 and W == 0:
break
for i in range(0, H):
print('#' * W)
print() | [["-", 0, 7, 8, 196, 0, 1, 0, 662, 31, 22], ["-", 0, 7, 8, 196, 0, 1, 0, 662, 0, 32], ["+", 0, 7, 8, 196, 0, 1, 0, 652, 63, 22], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 24], ["-", 8, 196, 0, 1, 0, 662, 12, 657, 17, 72], ["-", 0, 1, 0, 662, 12, 657, 12, 557, 0, 654], ["-", 0, 1, 0, 662, 12, 657, 12, 557, 0, 6], ["-", 0, 1,... | 5 | 54 |
import sys
for l in sys.stdin:
H, W = map(int,l.split())
if H == 0 and W == 0:
print ('\n')
break
for h in range(H):
print (W * '#')
print ('\n') | import sys
for l in sys.stdin:
H, W = map(int,l.split())
if H == 0 and W == 0:
break
for h in range(H):
print (W * '#')
print ('') | [["-", 0, 57, 64, 196, 0, 1, 0, 652, 63, 22], ["-", 64, 196, 0, 1, 0, 652, 3, 4, 0, 24], ["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 654], ["-", 0, 652, 3, 4, 0, 557, 0, 6, 0, 44], ["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 655], ["-", 64, 196, 0, 1, 0, 652, 3, 4, 0, 25]] | 5 | 61 |
while 1:
H,W = map(int,input().split())
if H == 0 and W == 0:
break
else:
x = "#" * W
for i in range(H):
print(x) | while 1:
H,W = map(int,input().split())
if H == 0 and W == 0:
break
x = "#" * W
for i in range(H):
print(x)
print("") | [["-", 0, 52, 8, 196, 0, 57, 75, 76, 0, 95], ["-", 0, 52, 8, 196, 0, 57, 75, 76, 0, 102], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 25], ["+", 0, 52, 8, 196, 0, 1, 0, 652, 63, 22], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 24], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 654], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 655]] | 5 | 50 |
# -*- coding: utf-8 -*
while True:
h, w = map(int, input().split())
if h == 0 and w == 0:
break
for i in range(h):
for j in range(w):
print('#', end='')
print('\n', end='') | # -*- coding: utf-8 -*
while True:
h, w = map(int, input().split())
if h == 0 and w == 0:
break
for i in range(h):
for j in range(w):
print('#', end='')
print()
print() | [["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 654], ["-", 0, 652, 3, 4, 0, 557, 0, 6, 0, 44], ["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 655], ["-", 8, 196, 0, 1, 0, 652, 3, 4, 0, 21], ["-", 0, 1, 0, 652, 3, 4, 0, 653, 141, 22], ["-", 0, 1, 0, 652, 3, 4, 0, 653, 0, 32], ["-", 0, 652, 3, 4, 0, 653, 51, 557, 0, 654], ["-", 0, 652, 3, ... | 5 | 68 |
while True:
a,b=input().split()
h=int(a)
w=int(b)
if h ==0 and w==0:
break
for i in range(h):
print("#"*w)
| while True:
a,b=input().split()
h=int(a)
w=int(b)
if h ==0 and w==0:
break
else:
for i in range(h):
print("#"*w)
print('')
| [["+", 0, 52, 8, 196, 0, 57, 75, 76, 0, 95], ["+", 0, 52, 8, 196, 0, 57, 75, 76, 0, 102], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 25], ["+", 75, 76, 8, 196, 0, 1, 0, 652, 63, 22], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 24], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 654], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 655]] | 5 | 52 |
while True:
w,h = list(map(int,input().split()))
if w == h == 0:
break
for i in range(h):
print("#"*w) | while True:
w,h = list(map(int,input().split()))
if w == h == 0:
break
for i in range(w):
print("#"*h)
print("") | [["-", 8, 196, 0, 7, 12, 652, 3, 4, 0, 22], ["+", 8, 196, 0, 7, 12, 652, 3, 4, 0, 22], ["-", 0, 1, 0, 652, 3, 4, 0, 657, 12, 22], ["+", 0, 1, 0, 652, 3, 4, 0, 657, 12, 22], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 25], ["+", 0, 52, 8, 196, 0, 1, 0, 652, 63, 22], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 24], ["+", 0, 1, 0, 652,... | 5 | 46 |
while 1:
H, W = map(int, input().split())
if W == 0 and H == 0:
break
for h in range(H):
print('#'* W)
print('\n') | while 1:
H, W = map(int, input().split())
if H == 0 and W == 0:
break
else:
for h in range(H):
print('#' * W)
print() | [["-", 8, 196, 0, 57, 15, 679, 31, 666, 0, 22], ["+", 8, 196, 0, 57, 15, 679, 31, 666, 0, 22], ["-", 8, 196, 0, 57, 15, 679, 12, 666, 0, 22], ["+", 8, 196, 0, 57, 15, 679, 12, 666, 0, 22], ["+", 0, 52, 8, 196, 0, 57, 75, 76, 0, 95], ["+", 0, 52, 8, 196, 0, 57, 75, 76, 0, 102], ["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 654],... | 5 | 51 |
(function(input) {
var n = Number(input);
var a = [];
for (var i = 1; i <= n; i++) {
if (i % 3 === 0) {
a.push(i);
continue;
}
var x = i;
do {
if (x % 10 === 3) {
a.push(i);
}
x = Math.floor(x / 10);
} while (x)
}
console.log(' ' + a.join(' '));
})(require('fs').readFileSync('/dev/st... | (function(input) {
var n = Number(input);
var a = [];
for (var i = 1; i <= n; i++) {
if (i % 3 === 0) {
a.push(i);
continue;
}
var x = i;
do {
if (x % 10 === 3) {
a.push(i);
break;
}
x = Math.floor(x / 10);
} while (x)
}
console.log(' ' + a.join(' '));
})(require('fs').readFile... | [["+", 8, 556, 0, 57, 64, 556, 0, 93, 0, 94], ["+", 8, 556, 0, 57, 64, 556, 0, 93, 0, 35]] | 2 | 135 |
var input = require("fs").readFileSync("/dev/stdin", "utf8");
input = input.split("\n");
var oup = "";
for (let i = 3; i <= input[0]; i++) {
if (i % 3 == 0 || toString(i).indexOf("3") != -1)
oup += " " + i;
}
console.log(oup);
| var input = require("fs").readFileSync("/dev/stdin", "utf8");
input = input.split("\n");
var oup = "";
for (let i = 3; i <= input[0]; i++) {
if (i % 3 == 0 || String(i).indexOf('3') != -1)
oup += " " + i
}
console.log(oup);
| [["-", 12, 16, 31, 2, 63, 558, 500, 2, 63, 22], ["+", 12, 16, 31, 2, 63, 558, 500, 2, 63, 22], ["-", 12, 16, 31, 2, 3, 3, 0, 557, 0, 62], ["+", 12, 16, 31, 2, 3, 3, 0, 557, 0, 104], ["-", 0, 7, 8, 556, 0, 57, 64, 1, 0, 35]] | 2 | 95 |
<?php
fscanf(STDIN, "%d", $n);
call($n);
function call($n)
{
for ($i = 1; $i <= $n; $i++) {
$x = $i;
if (0 == $x % 3) {
echo " $i";
continue;
}
while ($x >= 10) {
if (3 == $x % 10) {
echo " $i";
break;
... | <?php
fscanf(STDIN, "%d", $n);
call($n);
function call($n)
{
for ($i = 1; $i <= $n; $i++) {
$x = $i;
if (0 == $x % 3) {
echo " $i";
continue;
}
while ($x > 0) {
if (3 == $x % 10) {
echo " $i";
break;
... | [["-", 0, 9, 0, 52, 15, 23, 0, 16, 17, 20], ["-", 0, 9, 0, 52, 15, 23, 0, 16, 12, 612], ["+", 0, 9, 0, 52, 15, 23, 0, 16, 17, 47], ["+", 0, 9, 0, 52, 15, 23, 0, 16, 12, 612]] | 6 | 117 |
<?php
$inputNum = trim(fgets(STDIN));
$conditionMatchedNum = array();
for ($i = 1; $i <= $inputNum; $i++) {
$num = $i;
if ($num % 3 == 0) {
$conditionMatchedNum[] = $num;
continue;
}
while ($num) {
if ($num % 10 == 3) {
$conditionMatchedNum[] = $num;
brea... | <?php
$inputNum = trim(fgets(STDIN));
$conditionMatchedNum = array();
for ($i = 1; $i <= $inputNum; $i++) {
$num = $i;
if ($num % 3 == 0) {
$conditionMatchedNum[] = $i;
continue;
}
while ($num) {
if ($num % 10 == 3) {
$conditionMatchedNum[] = $i;
break;
... | [["-", 8, 9, 0, 1, 0, 11, 12, 606, 0, 141], ["+", 8, 9, 0, 1, 0, 11, 12, 606, 0, 141], ["-", 0, 608, 0, 563, 0, 16, 31, 609, 0, 62], ["+", 0, 608, 0, 563, 0, 16, 31, 557, 0, 104], ["-", 12, 613, 3, 3, 0, 28, 0, 609, 0, 62], ["+", 12, 613, 3, 3, 0, 28, 0, 557, 0, 104]] | 6 | 121 |
<?php
$inputNum = trim(fgets(STDIN));
for ($i=1; $i <= $inputNum; $i++) {
if (($i % 3 == 0) || preg_match('/3/', $i))
$nums[] = $i;
}
echo sprintf(' %d',implode(' ', $nums)), PHP_EOL; | <?php
$inputNum = trim(fgets(STDIN));
for ($i=1; $i <= $inputNum; $i++) {
if (($i % 3 == 0) || preg_match('/3/', $i))
$nums[] = $i;
}
echo sprintf(' %s', implode(' ', $nums)), PHP_EOL; | [["-", 0, 613, 3, 3, 0, 28, 0, 557, 0, 610], ["+", 0, 613, 3, 3, 0, 28, 0, 557, 0, 610]] | 6 | 80 |
<?php
$inputNum = trim(fgets(STDIN));
for ($i=1; $i <= $inputNum; $i++) {
if (($i % 3 == 0) || preg_match('/3/', $i))
$nums[] = $i;
}
echo sprintf(' %d',implode(' ', $nums)), PHP_EOL; | <?php
$inputNum = trim(fgets(STDIN));
for ($i=1; $i <= $inputNum; $i++) {
if (($i % 3 == 0) || preg_match('/3/', $i)) {
$nums[] = $i;
}
}
echo sprintf(' %s', implode(' ', $nums)), PHP_EOL; | [["+", 0, 7, 0, 9, 0, 57, 8, 9, 0, 45], ["+", 0, 7, 0, 9, 0, 57, 8, 9, 0, 46], ["-", 0, 613, 3, 3, 0, 28, 0, 557, 0, 610], ["+", 0, 613, 3, 3, 0, 28, 0, 557, 0, 610]] | 6 | 80 |
<?php
$inputNum = getInput();
for ($i = 1; $i <= $inputNum; $i++) {
if (($i % 3 == 0) || preg_match('/3/', $i)) {
$conditionMatchedNum[] = $i;
}
}
echo sprintf(' %d', implode(' ', $conditionMatchedNum)), PHP_EOL;
function getInput()
{
return trim(fgets(STDIN));
} | <?php
$inputNum = getInput();
for ($i = 1; $i <= $inputNum; $i++) {
if (($i % 3 == 0) || preg_match('/3/', $i)) {
$conditionMatchedNum[] = $i;
}
}
echo sprintf(' %s', implode(' ', $conditionMatchedNum)), PHP_EOL;
function getInput()
{
return trim(fgets(STDIN));
} | [["-", 0, 613, 3, 3, 0, 28, 0, 557, 0, 610], ["+", 0, 613, 3, 3, 0, 28, 0, 557, 0, 610]] | 6 | 93 |
<?php
$n=trim(fgets(STDIN));
$o='';
for($i=1;$i<=$n;$i++){
$x=$i;
if(0==$x%3) $o.=' '.$i;
else{
while($x){
if(3==$x%3){
$o.=' '.$i;
break;
}
$x=floor($x/10);
}
}
}
print $o;
?> | <?php
$n=trim(fgets(STDIN));
$o='';
for($i=1;$i<=$n;$i++){
$x=$i;
if(0==$x%3) $o.=' '.$i;
else{
while($x){
if(3==$x%10){
$o.=' '.$i;
break;
}
$x=floor($x/10);
}
}
}
print $o;
?> | [["-", 0, 57, 15, 23, 0, 16, 12, 16, 12, 612], ["+", 0, 57, 15, 23, 0, 16, 12, 16, 12, 612]] | 6 | 111 |
<?php
$n=(int)trim(fgets(STDIN));
$o='';
for($i=1;$i<=$n;$i++){
if($x%3==0) $o.=' '.$i;
else{
$x=$i;
while($x){
if($x%10==3){
$o.=' '.$i;
break;
}
$x=floor($x/10);
}
}
}
print $o;
?> | <?php
$n=(int)trim(fgets(STDIN));
$o='';
for($i=1;$i<=$n;$i++){
if($i%3==0) $o.=' '.$i;
else{
$x=$i;
while($x){
if($x%10==3){
$o.=' '.$i;
break;
}
$x=floor($x/10);
}
}
}
print $o;
?> | [["-", 15, 23, 0, 16, 31, 16, 31, 606, 0, 141], ["+", 15, 23, 0, 16, 31, 16, 31, 606, 0, 141]] | 6 | 114 |
<?php
$n = (int)trim(fgets(STDIN));
$str = '';
for ($i=3; $i<=$n; ++$i) {
if (($i % 3 === 0) || strpos((string)$i, '3')) $str .= " $i";
}
echo $str, PHP_EOL; | <?php
$n = (int)trim(fgets(STDIN));
$str = '';
for ($i=3; $i<=$n; ++$i) {
if (($i % 3 === 0) || (strpos((string)$i, '3') !== false) ) $str .= " $i";
}
echo $str, PHP_EOL; | [["+", 0, 57, 15, 23, 0, 16, 12, 23, 0, 24], ["+", 12, 23, 0, 16, 31, 613, 3, 3, 0, 25], ["+", 15, 23, 0, 16, 12, 23, 0, 16, 17, 566], ["+", 15, 23, 0, 16, 12, 23, 0, 16, 12, 626]] | 6 | 79 |
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
for (int i = 1; i <= n; i++) {
int x = i;
if (x % 3 == 0) {
System.out.print(" " + x);
} else {
String value = String.valueO... | import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
for (int i = 1; i <= n; i++) {
int x = i;
if (x % 3 == 0) {
System.out.print(" " + x);
} else {
String value = String.valueO... | [["+", 8, 196, 0, 57, 64, 196, 0, 93, 0, 94], ["+", 8, 196, 0, 57, 64, 196, 0, 93, 0, 35]] | 3 | 172 |
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
int z;
for (int i = 3; i <= n; i++) {
z = i;
if (z % 3 == 0) {
System.out.print(" " + i);
}
while (z != 0) {
if (z... | import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
int z;
for (int i = 3; i <= n; i++) {
z = i;
if (z % 3 == 0) {
System.out.print(" " + i);
continue;
}
while (z != ... | [["+", 8, 196, 0, 57, 64, 196, 0, 116, 0, 117], ["+", 8, 196, 0, 57, 64, 196, 0, 116, 0, 35]] | 3 | 137 |
import java.util.Scanner;
class Main {
public static void main(String args[]) {
Scanner scan = new Scanner(System.in);
int n = scan.nextInt();
int i = 1;
for (; i <= n + 1; i++) {
if (i % 3 == 0) {
System.out.print(" " + i);
} else {
int j = i;
while (j > 0) ... | import java.util.Scanner;
class Main {
public static void main(String args[]) {
Scanner scan = new Scanner(System.in);
int n = scan.nextInt();
int i = 1;
for (; i <= n; i++) {
if (i % 3 == 0) {
System.out.print(" " + i);
} else {
int j = i;
while (j > 0) {
... | [["-", 8, 196, 0, 7, 15, 16, 12, 16, 17, 72], ["-", 8, 196, 0, 7, 15, 16, 12, 16, 12, 499]] | 3 | 138 |
import java.io.BufferedReader;
import java.io.InputStreamReader;
public class Main {
public static void main(String[] args) throws Exception {
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
String str;
int n = 0;
while ((str = br.readLine()) != null) {
n = Integer.par... | import java.io.BufferedReader;
import java.io.InputStreamReader;
public class Main {
public static void main(String[] args) throws Exception {
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
String str;
int n = 0;
while ((str = br.readLine()) != null) {
n = Integer.par... | [["+", 8, 196, 0, 57, 64, 196, 0, 93, 0, 94], ["+", 8, 196, 0, 57, 64, 196, 0, 93, 0, 35]] | 3 | 183 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.