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
| change_count
int64 0
100
|
|---|---|---|---|---|---|
using System;
class MainClass {
public static void Main(string[] args) {
string str = Console.ReadLine();
int w = Convert.ToInt32(str.Split(' ')[0]);
int h = Convert.ToInt32(str.Split(' ')[1]);
int x = Convert.ToInt32(str.Split(' ')[2]);
int y = Convert.ToInt32(str.Split(' ')[3]);
int r = Convert.ToInt32(str.Split(' ')[4]);
if ((x - r) > 0 && (y - r) > 0 && (x + r) < w && (y + r) < h) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
|
using System;
class MainClass {
public static void Main(string[] args) {
string str = Console.ReadLine();
int w = Convert.ToInt32(str.Split(' ')[0]);
int h = Convert.ToInt32(str.Split(' ')[1]);
int x = Convert.ToInt32(str.Split(' ')[2]);
int y = Convert.ToInt32(str.Split(' ')[3]);
int r = Convert.ToInt32(str.Split(' ')[4]);
if ((x - r) >= 0 && (y - r) >= 0 && (x + r) <= w && (y + r) <= h) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
|
[["-", 15, 16, 31, 16, 31, 16, 31, 16, 17, 47], ["+", 15, 16, 31, 16, 31, 16, 31, 16, 17, 20], ["-", 15, 16, 31, 16, 31, 16, 12, 16, 17, 47], ["+", 15, 16, 31, 16, 31, 16, 12, 16, 17, 20], ["-", 0, 57, 15, 16, 31, 16, 12, 16, 17, 18], ["+", 0, 57, 15, 16, 31, 16, 12, 16, 17, 19], ["-", 8, 196, 0, 57, 15, 16, 12, 16, 17, 18], ["+", 8, 196, 0, 57, 15, 16, 12, 16, 17, 19]]
| 8
| 185
| 8
|
using System;
using System.Collections.Generic;
using System.Linq;
namespace AOJ {
public class AOJ {
public static void Main(string[] args) {
var n = Console.ReadLine().Split(' ').ToList().Select(int.Parse).ToArray();
if (0 <= (n[2] - n[4]) && 0 <= (n[3] - n[4]) && n[0] > (n[2] + n[4]) &&
n[1] > (n[3] + n[4]))
Console.WriteLine("Yes");
else
Console.WriteLine("No");
}
}
}
|
using System;
using System.Collections.Generic;
using System.Linq;
namespace AOJ {
public class AOJ {
public static void Main(string[] args) {
var n = Console.ReadLine().Split(' ').ToList().Select(int.Parse).ToArray();
if (0 <= (n[2] - n[4]) && 0 <= (n[3] - n[4]) && n[0] >= (n[2] + n[4]) &&
n[1] >= (n[3] + n[4]))
Console.WriteLine("Yes");
else
Console.WriteLine("No");
}
}
}
|
[["-", 0, 57, 15, 16, 31, 16, 12, 16, 17, 47], ["+", 0, 57, 15, 16, 31, 16, 12, 16, 17, 20], ["-", 8, 196, 0, 57, 15, 16, 12, 16, 17, 47], ["+", 8, 196, 0, 57, 15, 16, 12, 16, 17, 20]]
| 8
| 150
| 4
|
using System;
namespace AOJ {
class Program {
static void Main(string[] args) {
bool x = true, y = true;
string read = Console.ReadLine(), msg;
var temp_string = read.Split(' ');
int box_w = int.Parse(temp_string[0]), box_h = int.Parse(temp_string[1]),
circle_x = int.Parse(temp_string[2]),
circle_y = int.Parse(temp_string[3]),
circle_r = int.Parse(temp_string[4]);
if (circle_x - circle_r < 0 || circle_x + circle_r > box_w) {
x = false;
}
if (circle_y - circle_r < 0 || circle_y + circle_r > box_h) {
y = false;
}
if (x || y) {
msg = "Yes";
} else {
msg = "No";
}
Console.WriteLine(msg);
Console.ReadLine();
}
}
}
|
using System;
namespace AOJ {
class Program {
static void Main(string[] args) {
bool x = true, y = true;
string read = Console.ReadLine(), msg;
var temp_string = read.Split(' ');
int box_w = int.Parse(temp_string[0]), box_h = int.Parse(temp_string[1]),
circle_x = int.Parse(temp_string[2]),
circle_y = int.Parse(temp_string[3]),
circle_r = int.Parse(temp_string[4]);
if (circle_x - circle_r < 0 || circle_x + circle_r > box_w) {
x = false;
}
if (circle_y - circle_r < 0 || circle_y + circle_r > box_h) {
y = false;
}
if (x && y) {
msg = "Yes";
} else {
msg = "No";
}
Console.WriteLine(msg);
Console.ReadLine();
}
}
}
|
[["-", 0, 195, 8, 196, 0, 57, 15, 16, 17, 106], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 17, 98]]
| 8
| 191
| 2
|
using System;
class MainClass {
public static void Main(string[] args) {
string str = Console.ReadLine();
string[] spStr = str.Split(' ');
int w = int.Parse(spStr[0]);
int h = int.Parse(spStr[1]);
int x = int.Parse(spStr[2]);
int y = int.Parse(spStr[3]);
int r = int.Parse(spStr[4]);
if (w >= (x + r) && 0 >= (x - r) && h >= (y + r) && 0 >= (y - r)) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
|
using System;
class MainClass {
public static void Main(string[] args) {
string str = Console.ReadLine();
string[] spStr = str.Split(' ');
int w = int.Parse(spStr[0]);
int h = int.Parse(spStr[1]);
int x = int.Parse(spStr[2]);
int y = int.Parse(spStr[3]);
int r = int.Parse(spStr[4]);
if (w >= (x + r) && 0 <= (x - r) && h >= (y + r) && 0 <= (y - r)) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
|
[["-", 15, 16, 31, 16, 31, 16, 12, 16, 17, 20], ["+", 15, 16, 31, 16, 31, 16, 12, 16, 17, 19], ["-", 8, 196, 0, 57, 15, 16, 12, 16, 17, 20], ["+", 8, 196, 0, 57, 15, 16, 12, 16, 17, 19]]
| 8
| 164
| 4
|
using System;
namespace Circle_in_a_Rectangle {
class MainClass {
public static void Main(string[] args) {
string[] str = Console.ReadLine().Split(' ');
int w = int.Parse(str[0]);
int h = int.Parse(str[1]);
int x = int.Parse(str[2]);
int y = int.Parse(str[3]);
int r = int.Parse(str[4]);
if (x - r > 0 && x + r < w && y - r > 0 && y + r < h) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
}
|
using System;
namespace Circle_in_a_Rectangle {
class MainClass {
public static void Main(string[] args) {
string[] str = Console.ReadLine().Split(' ');
int w = int.Parse(str[0]);
int h = int.Parse(str[1]);
int x = int.Parse(str[2]);
int y = int.Parse(str[3]);
int r = int.Parse(str[4]);
if (x - r >= 0 && x + r <= w && y - r >= 0 && y + r <= h) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
}
|
[["-", 15, 16, 31, 16, 31, 16, 31, 16, 17, 47], ["+", 15, 16, 31, 16, 31, 16, 31, 16, 17, 20], ["-", 15, 16, 31, 16, 31, 16, 12, 16, 17, 18], ["+", 15, 16, 31, 16, 31, 16, 12, 16, 17, 19], ["-", 0, 57, 15, 16, 31, 16, 12, 16, 17, 47], ["+", 0, 57, 15, 16, 31, 16, 12, 16, 17, 20], ["-", 8, 196, 0, 57, 15, 16, 12, 16, 17, 18], ["+", 8, 196, 0, 57, 15, 16, 12, 16, 17, 19]]
| 8
| 155
| 8
|
using System;
namespace ConsoleApplication3 {
class Program {
static void Main(string[] args) {
string[] input = Console.ReadLine().Split(' ');
int W = int.Parse(input[0]);
int H = int.Parse(input[1]);
int x = int.Parse(input[2]);
int y = int.Parse(input[3]);
int r = int.Parse(input[4]);
if (calc(W, H, x, y, r)) {
Console.WriteLine("YES");
} else {
Console.WriteLine("NO");
}
}
static private bool calc(int W, int H, int x, int y, int r) {
if ((x + r <= W && x - r >= 0) && (y + r <= H && y - r >= 0)) {
return true;
}
return false;
}
}
}
|
using System;
namespace ConsoleApplication3 {
class Program {
static void Main(string[] args) {
string[] input = Console.ReadLine().Split(' ');
int W = int.Parse(input[0]);
int H = int.Parse(input[1]);
int x = int.Parse(input[2]);
int y = int.Parse(input[3]);
int r = int.Parse(input[4]);
if (calc(W, H, x, y, r)) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
static private bool calc(int W, int H, int x, int y, int r) {
if ((x + r <= W && x - r >= 0) && (y + r <= H && y - r >= 0)) {
return true;
}
return false;
}
}
}
|
[["-", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222], ["+", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222]]
| 8
| 203
| 4
|
using System;
using System.Collections.Generic;
class ITP1 {
static void Main(string[] args) {
Q2_D();
// var exStdIn = new System.IO.StreamReader("stdin.txt");
// System.Console.SetIn(exStdIn);
// int[] a = Array.ConvertAll(Console.ReadLine().Split(' '), new
// Converter<String, int>(s => int.Parse(s)));
}
static void Q1() {
int input = int.Parse(Console.ReadLine());
int h = input / 3600;
int m = input % 3600 / 60;
int s = input % 3600 % 60;
Console.WriteLine(String.Format("{0}:{1}:{2}", h, m, s));
}
static void Q2_A() {
int[] a = Array.ConvertAll(Console.ReadLine().Split(' '),
new Converter<String, int>(s => int.Parse(s)));
String sign = a[0] - a[1] > 0 ? ">" : a[0] - a[1] == 0 ? "==" : "<";
Console.WriteLine(String.Format("a {0} b", sign));
}
static void Q2_B() {
int[] a = Array.ConvertAll(Console.ReadLine().Split(' '),
new Converter<String, int>(s => int.Parse(s)));
String answer = a[2] - a[1] > 0 ? a[1] - a[0] > 0 ? "Yes" : "No" : "No";
Console.WriteLine(answer);
}
static void Q2_C() {
List<int> a = new List<int>(
Array.ConvertAll(Console.ReadLine().Split(' '),
new Converter<String, int>(s => int.Parse(s))));
a.Sort();
Console.WriteLine(String.Format("{0} {1} {2}", a[0], a[1], a[2]));
}
static void Q2_D() {
int[] a = Array.ConvertAll(Console.ReadLine().Split(' '),
new Converter<String, int>(s => int.Parse(s)));
int chk = 0;
// x-max
if (a[0] - a[2] + a[4] >= 0)
chk++;
// x-min
if (a[2] - a[4] >= 0)
chk++;
// y-max
if (a[1] - a[3] + a[4] >= 0)
chk++;
// y-min
if (a[3] - a[4] >= 0)
chk++;
String answer = chk == 4 ? "Yes" : "No";
Console.WriteLine(answer);
}
}
|
using System;
using System.Collections.Generic;
class ITP1 {
static void Main(string[] args) {
// var exStdIn = new System.IO.StreamReader("stdin.txt");
// System.Console.SetIn(exStdIn);
Q2_D();
// int[] a = Array.ConvertAll(Console.ReadLine().Split(' '), new
// Converter<String, int>(s => int.Parse(s)));
}
static void Q1() {
int input = int.Parse(Console.ReadLine());
int h = input / 3600;
int m = input % 3600 / 60;
int s = input % 3600 % 60;
Console.WriteLine(String.Format("{0}:{1}:{2}", h, m, s));
}
static void Q2_A() {
int[] a = Array.ConvertAll(Console.ReadLine().Split(' '),
new Converter<String, int>(s => int.Parse(s)));
String sign = a[0] - a[1] > 0 ? ">" : a[0] - a[1] == 0 ? "==" : "<";
Console.WriteLine(String.Format("a {0} b", sign));
}
static void Q2_B() {
int[] a = Array.ConvertAll(Console.ReadLine().Split(' '),
new Converter<String, int>(s => int.Parse(s)));
String answer = a[2] - a[1] > 0 ? a[1] - a[0] > 0 ? "Yes" : "No" : "No";
Console.WriteLine(answer);
}
static void Q2_C() {
List<int> a = new List<int>(
Array.ConvertAll(Console.ReadLine().Split(' '),
new Converter<String, int>(s => int.Parse(s))));
a.Sort();
Console.WriteLine(String.Format("{0} {1} {2}", a[0], a[1], a[2]));
}
static void Q2_D() {
int[] a = Array.ConvertAll(Console.ReadLine().Split(' '),
new Converter<String, int>(s => int.Parse(s)));
int chk = 0;
// x-max
if (a[0] - a[2] - a[4] >= 0)
chk++;
// x-min
if (a[2] - a[4] >= 0)
chk++;
// y-max
if (a[1] - a[3] - a[4] >= 0)
chk++;
// y-min
if (a[3] - a[4] >= 0)
chk++;
String answer = chk == 4 ? "Yes" : "No";
Console.WriteLine(answer);
}
}
|
[["-", 8, 196, 0, 57, 15, 16, 31, 16, 17, 72], ["+", 8, 196, 0, 57, 15, 16, 31, 16, 17, 33]]
| 8
| 544
| 4
|
using System;
using System.Collections.Generic;
class A {
public static void Main() {
string[] input = Console.ReadLine().Split(' ');
int W = int.Parse(input[0]);
int H = int.Parse(input[1]);
int x = int.Parse(input[2]);
int y = int.Parse(input[3]);
int r = int.Parse(input[4]);
if (W > (x + r) && 0 <= (x - r) && H > (y + r) && 0 <= (y - r)) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
|
using System;
using System.Collections.Generic;
class A {
public static void Main() {
string[] input = Console.ReadLine().Split(' ');
int W = int.Parse(input[0]);
int H = int.Parse(input[1]);
int x = int.Parse(input[2]);
int y = int.Parse(input[3]);
int r = int.Parse(input[4]);
if (W >= (x + r) && 0 <= (x - r) && H >= (y + r) && 0 <= (y - r)) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
|
[["-", 15, 16, 31, 16, 31, 16, 31, 16, 17, 47], ["+", 15, 16, 31, 16, 31, 16, 31, 16, 17, 20], ["-", 0, 57, 15, 16, 31, 16, 12, 16, 17, 47], ["+", 0, 57, 15, 16, 31, 16, 12, 16, 17, 20]]
| 8
| 162
| 4
|
using System;
using System.Linq;
namespace _2_D {
class Program {
static void Main(string[] args) {
int[] X = Console.ReadLine().Split().Select(int.Parse).ToArray();
int W = X[0];
int H = X[1];
int x = X[2];
int y = X[3];
int r = X[4];
if (x > r && x + r < W && y > r && y + r < H) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
}
|
using System;
using System.Linq;
namespace _2_D {
class Program {
static void Main(string[] args) {
int[] X = Console.ReadLine().Split().Select(int.Parse).ToArray();
int W = X[0];
int H = X[1];
int x = X[2];
int y = X[3];
int r = X[4];
if (x >= r && x + r <= W && y >= r && y + r <= H) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
}
|
[["-", 15, 16, 31, 16, 31, 16, 31, 16, 17, 47], ["+", 15, 16, 31, 16, 31, 16, 31, 16, 17, 20], ["-", 15, 16, 31, 16, 31, 16, 12, 16, 17, 18], ["+", 15, 16, 31, 16, 31, 16, 12, 16, 17, 19], ["-", 0, 57, 15, 16, 31, 16, 12, 16, 17, 47], ["+", 0, 57, 15, 16, 31, 16, 12, 16, 17, 20], ["-", 8, 196, 0, 57, 15, 16, 12, 16, 17, 18], ["+", 8, 196, 0, 57, 15, 16, 12, 16, 17, 19]]
| 8
| 138
| 8
|
using System;
class Program {
public static void Main(string[] args) {
string data = Console.ReadLine();
string[] arg = data.Split();
// WW???HH???xx???yy???rr
int W = int.Parse(arg[0]);
int H = int.Parse(arg[1]);
int x = int.Parse(arg[2]);
int y = int.Parse(arg[3]);
int r = int.Parse(arg[4]);
// x :r~W-r
// y :r~H-r
if (((r < x) && (x < (W - r))) && ((r < y) && (y < (H - r))))
Console.WriteLine("Yes");
else
Console.WriteLine("No");
}
}
|
using System;
class Program {
public static void Main(string[] args) {
string data = Console.ReadLine();
string[] arg = data.Split();
// WW???HH???xx???yy???rr
int W = int.Parse(arg[0]);
int H = int.Parse(arg[1]);
int x = int.Parse(arg[2]);
int y = int.Parse(arg[3]);
int r = int.Parse(arg[4]);
// x :r~W-r
// y :r~H-r
if (((r <= x) && (x <= (W - r))) && ((r <= y) && (y <= (H - r))))
Console.WriteLine("Yes");
else
Console.WriteLine("No");
}
}
|
[["-", 31, 23, 0, 16, 31, 23, 0, 16, 17, 18], ["+", 31, 23, 0, 16, 31, 23, 0, 16, 17, 19], ["-", 31, 23, 0, 16, 12, 23, 0, 16, 17, 18], ["+", 31, 23, 0, 16, 12, 23, 0, 16, 17, 19], ["-", 12, 23, 0, 16, 31, 23, 0, 16, 17, 18], ["+", 12, 23, 0, 16, 31, 23, 0, 16, 17, 19], ["-", 12, 23, 0, 16, 12, 23, 0, 16, 17, 18], ["+", 12, 23, 0, 16, 12, 23, 0, 16, 17, 19]]
| 8
| 164
| 8
|
using System;
class P {
public static void Main() {
//????????????????????????
string a = Console.ReadLine();
//?????????????????????????????????
var b = a.Split(' ');
//?????°???????????????
int W = Int32.Parse(b[0]);
int H = Int32.Parse(b[1]);
int x = Int32.Parse(b[2]);
int y = Int32.Parse(b[3]);
int r = Int32.Parse(b[4]);
//?????¶??????
if (r < x & x < W - r & r < y & y < H - r) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
|
using System;
class P {
public static void Main() {
//????????????????????????
string a = Console.ReadLine();
//?????????????????????????????????
var b = a.Split(' ');
//?????°???????????????
int W = Int32.Parse(b[0]);
int H = Int32.Parse(b[1]);
int x = Int32.Parse(b[2]);
int y = Int32.Parse(b[3]);
int r = Int32.Parse(b[4]);
//?????¶??????
if (r <= x & x <= W - r & r <= y & y <= H - r) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
|
[["-", 15, 16, 31, 16, 31, 16, 31, 16, 17, 18], ["+", 15, 16, 31, 16, 31, 16, 31, 16, 17, 19], ["-", 15, 16, 31, 16, 31, 16, 12, 16, 17, 18], ["+", 15, 16, 31, 16, 31, 16, 12, 16, 17, 19], ["-", 0, 57, 15, 16, 31, 16, 12, 16, 17, 18], ["+", 0, 57, 15, 16, 31, 16, 12, 16, 17, 19], ["-", 8, 196, 0, 57, 15, 16, 12, 16, 17, 18], ["+", 8, 196, 0, 57, 15, 16, 12, 16, 17, 19]]
| 8
| 150
| 8
|
public class Circle_in_a_Rectangle {
static void Main(string[] args) {
var line = System.Console.ReadLine().Trim().Split(' ');
int x = int.Parse(line[0]);
int y = int.Parse(line[1]);
int w = int.Parse(line[2]);
int h = int.Parse(line[3]);
int r = int.Parse(line[4]);
string result = "No";
if (r <= x && x <= w - r && r <= y && y <= h - r) {
result = "Yes";
}
System.Console.WriteLine(result);
}
}
|
public class Circle_in_a_Rectangle {
static void Main(string[] args) {
var line = System.Console.ReadLine().Trim().Split(' ');
int w = int.Parse(line[0]);
int h = int.Parse(line[1]);
int x = int.Parse(line[2]);
int y = int.Parse(line[3]);
int r = int.Parse(line[4]);
string result = "No";
if (r <= x && x <= w - r && r <= y && y <= h - r) {
result = "Yes";
}
System.Console.WriteLine(result);
}
}
|
[["-", 8, 196, 0, 197, 0, 198, 0, 200, 141, 22], ["+", 8, 196, 0, 197, 0, 198, 0, 200, 141, 22]]
| 8
| 149
| 8
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.IO;
namespace StartFinish {
class Program {
static void Main(string[] args) {
int[] WHxyr = Console.ReadLine().Split(' ').Select(int.Parse).ToArray();
int W = WHxyr[0];
int H = WHxyr[1];
int x = WHxyr[2];
int y = WHxyr[3];
int r = WHxyr[4];
bool isCan = false;
if ((x - r > 0) && (x + r < W) && (y + r < H) && (y - r > 0)) {
isCan = true;
}
if (isCan == true) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
}
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.IO;
namespace StartFinish {
class Program {
static void Main(string[] args) {
int[] WHxyr = Console.ReadLine().Split(' ').Select(int.Parse).ToArray();
int W = WHxyr[0];
int H = WHxyr[1];
int x = WHxyr[2];
int y = WHxyr[3];
int r = WHxyr[4];
bool isCan = false;
if ((x - r >= 0) && (x + r <= W) && (y + r <= H) && (y - r >= 0)) {
isCan = true;
}
if (isCan == true) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
}
|
[["-", 31, 16, 31, 16, 31, 23, 0, 16, 17, 47], ["+", 31, 16, 31, 16, 31, 23, 0, 16, 17, 20], ["-", 31, 16, 31, 16, 12, 23, 0, 16, 17, 18], ["+", 31, 16, 31, 16, 12, 23, 0, 16, 17, 19], ["-", 15, 16, 31, 16, 12, 23, 0, 16, 17, 18], ["+", 15, 16, 31, 16, 12, 23, 0, 16, 17, 19], ["-", 0, 57, 15, 16, 12, 23, 0, 16, 17, 47], ["+", 0, 57, 15, 16, 12, 23, 0, 16, 17, 20]]
| 8
| 187
| 8
|
using System;
using System.Collections.Generic;
// using System.Linq;
// using System.Text;
// using System.Threading.Tasks;
// namespace _2_D
//{
class Program {
static void Main(string[] args) {
string a = Console.ReadLine();
string[] b = a.Split(' ');
int W = int.Parse(b[0]);
int H = int.Parse(b[1]);
int x = int.Parse(b[2]);
int y = int.Parse(b[3]);
int r = int.Parse(b[4]);
// x??¨y?????§?¨????(0,0)??\?????§????????¨???
if ((x - r) < 0 || (x - r) > 0) {
Console.WriteLine("No");
}
// x + ?????????W???????????§????????¨???, y + ?????????H???????????§??????
else if ((x + r) > W || (y + r) > H) {
Console.WriteLine("No");
} else {
Console.WriteLine("Yes");
}
}
}
//}
|
using System;
using System.Collections.Generic;
// using System.Linq;
// using System.Text;
// using System.Threading.Tasks;
// namespace _2_D
//{
class Program {
static void Main(string[] args) {
string a = Console.ReadLine();
string[] b = a.Split(' ');
int W = int.Parse(b[0]);
int H = int.Parse(b[1]);
int x = int.Parse(b[2]);
int y = int.Parse(b[3]);
int r = int.Parse(b[4]);
// x??¨y?????§?¨????(0,0)??\?????§????????¨???
if ((x - r) < 0 || (y - r) < 0) {
Console.WriteLine("No");
}
// x + ?????????W???????????§????????¨???, y + ?????????H???????????§??????
else if ((x + r) > W || (y + r) > H) {
Console.WriteLine("No");
} else {
Console.WriteLine("Yes");
}
}
}
//}
|
[["-", 15, 16, 12, 16, 31, 23, 0, 16, 31, 22], ["+", 15, 16, 12, 16, 31, 23, 0, 16, 31, 22], ["-", 8, 196, 0, 57, 15, 16, 12, 16, 17, 47], ["+", 8, 196, 0, 57, 15, 16, 12, 16, 17, 18]]
| 8
| 192
| 4
|
// Branch on Condition - Circle in a Rectangle
// http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=ITP1_2_D
using System;
using System.Linq;
namespace NTL_2_D {
class Program {
public Program() {}
public static void Main() { new Program().Calc(); }
void Calc() {
var n = Input.Split(' ').Select(i => int.Parse(i)).ToArray();
Output(judge(n) ? "Yes" : "No");
}
String Input {
get { return Console.ReadLine(); }
}
void Output(String str) { Console.WriteLine(str); }
bool judge(int[] n) {
if (0 > n[2] - n[4])
return false;
if (0 > n[3] - n[4])
return false;
if (n[0] < n[2] + n[4])
return false;
if (n[1] < n[2] + n[4])
return false;
return true;
}
}
}
|
// Branch on Condition - Circle in a Rectangle
// http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=ITP1_2_D
using System;
using System.Linq;
namespace NTL_2_D {
class Program {
public Program() {}
public static void Main() { new Program().Calc(); }
void Calc() {
var n = Input.Split(' ').Select(i => int.Parse(i)).ToArray();
Output(judge(n) ? "Yes" : "No");
}
String Input {
get { return Console.ReadLine(); }
}
void Output(String str) { Console.WriteLine(str); }
bool judge(int[] n) {
if (0 > n[2] - n[4])
return false;
if (0 > n[3] - n[4])
return false;
if (n[0] < n[2] + n[4])
return false;
if (n[1] < n[3] + n[4])
return false;
return true;
}
}
}
|
[["-", 12, 16, 31, 204, 206, 207, 0, 28, 0, 203], ["+", 12, 16, 31, 204, 206, 207, 0, 28, 0, 203]]
| 8
| 207
| 2
|
using System;
using System.Linq;
class aizu_judge {
static void Main() {
int[] num = System.Console.ReadLine().Split().Select(int.Parse).ToArray();
if (num[0] - num[4] > num[2] && num[2] - num[4] > 0 &&
num[1] - num[4] > num[3] && num[3] - num[4] > 0) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
|
using System;
using System.Linq;
class aizu_judge {
static void Main() {
int[] num = System.Console.ReadLine().Split().Select(int.Parse).ToArray();
if (num[0] - num[4] >= num[2] && num[2] - num[4] >= 0 &&
num[1] - num[4] >= num[3] && num[3] - num[4] >= 0) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
|
[["-", 15, 16, 31, 16, 31, 16, 31, 16, 17, 47], ["+", 15, 16, 31, 16, 31, 16, 31, 16, 17, 20], ["-", 15, 16, 31, 16, 31, 16, 12, 16, 17, 47], ["+", 15, 16, 31, 16, 31, 16, 12, 16, 17, 20], ["-", 0, 57, 15, 16, 31, 16, 12, 16, 17, 47], ["+", 0, 57, 15, 16, 31, 16, 12, 16, 17, 20], ["-", 8, 196, 0, 57, 15, 16, 12, 16, 17, 47], ["+", 8, 196, 0, 57, 15, 16, 12, 16, 17, 20]]
| 8
| 126
| 8
|
using System;
class Program {
static void Main() {
string[] str = Console.ReadLine().Split(' ');
int[] nums = new int[str.Length];
for (int i = 0; i < nums.Length; i++) {
nums[i] = int.Parse(str[i]);
}
Console.WriteLine(IsInRectangle(nums[0], nums[1], nums[2], nums[4], nums[5])
? "Yes"
: "No");
}
static bool IsInRectangle(int width, int height, int x, int y, int r) {
if (x + r > width || x - r < 0 || y + r > height || y - r < 0) {
return false;
} else {
return true;
}
}
}
|
using System;
class Program {
static void Main() {
string[] str = Console.ReadLine().Split(' ');
int[] nums = new int[str.Length];
for (int i = 0; i < nums.Length; i++) {
nums[i] = int.Parse(str[i]);
}
Console.WriteLine(IsInRectangle(nums[0], nums[1], nums[2], nums[3], nums[4])
? "Yes"
: "No");
}
static bool IsInRectangle(int width, int height, int x, int y, int r) {
if (x + r > width || x - r < 0 || y + r > height || y - r < 0) {
return false;
} else {
return true;
}
}
}
|
[["-", 0, 28, 0, 204, 206, 207, 0, 28, 0, 203], ["+", 0, 28, 0, 204, 206, 207, 0, 28, 0, 203]]
| 8
| 177
| 4
|
// ITP1_2_D
// 1??????
using System;
using System.Collections.Generic;
/*using System.Linq;
using System.Text;
using System.Threading.Tasks;*/
class Program {
static void Main(string[] args) {
int W, H, x, y, r;
string[] sarray =
(Console.ReadLine().Split(' ')); //??????????????????????????????
//int??????iaaray???string??????sarray????????????????????\
int[] iarray = Array.ConvertAll<string, int>(
sarray, delegate(string value) { return int.Parse(value); });
//??£??\
W = iarray[0];
H = iarray[1];
x = iarray[2];
y = iarray[3];
r = iarray[4];
if (x - r > 0 && y - r > 0 && x + r <= W && y + r <= H) {
Console.WriteLine("Yes");
}
if (x - r <= 0 || y - r <= 0 || x + r > W || y + r > H) {
Console.WriteLine("No");
}
}
}
|
// ITP1_2_D
// 1??????
using System;
using System.Collections.Generic;
/*using System.Linq;
using System.Text;
using System.Threading.Tasks;*/
class Program {
static void Main(string[] args) {
int W, H, x, y, r;
string[] sarray =
(Console.ReadLine().Split(' ')); //??????????????????????????????
//int??????iaaray???string??????sarray????????????????????\
int[] iarray = Array.ConvertAll<string, int>(
sarray, delegate(string value) { return int.Parse(value); });
//??£??\
W = iarray[0];
H = iarray[1];
x = iarray[2];
y = iarray[3];
r = iarray[4];
if (x - r >= 0 && y - r >= 0 && x + r <= W && y + r <= H) {
Console.WriteLine("Yes");
}
if (x - r < 0 || y - r < 0 || x + r > W || y + r > H) {
Console.WriteLine("No");
}
}
}
|
[["-", 15, 16, 31, 16, 31, 16, 31, 16, 17, 47], ["+", 15, 16, 31, 16, 31, 16, 31, 16, 17, 20], ["-", 15, 16, 31, 16, 31, 16, 12, 16, 17, 47], ["+", 15, 16, 31, 16, 31, 16, 12, 16, 17, 20], ["-", 15, 16, 31, 16, 31, 16, 31, 16, 17, 19], ["+", 15, 16, 31, 16, 31, 16, 31, 16, 17, 18], ["-", 15, 16, 31, 16, 31, 16, 12, 16, 17, 19], ["+", 15, 16, 31, 16, 31, 16, 12, 16, 17, 18]]
| 8
| 204
| 8
|
using System;
class hoge {
static void Main() {
string input = Console.ReadLine();
int width = int.Parse(input.Split(' ')[0]);
int height = int.Parse(input.Split(' ')[1]);
int centerX = int.Parse(input.Split(' ')[2]);
int centerY = int.Parse(input.Split(' ')[3]);
int radius = int.Parse(input.Split(' ')[4]);
if (centerX - radius > 0 & centerX + radius<width & centerY - radius> 0 &
centerY + radius < height) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
|
using System;
class hoge {
static void Main() {
string input = Console.ReadLine();
int width = int.Parse(input.Split(' ')[0]);
int height = int.Parse(input.Split(' ')[1]);
int centerX = int.Parse(input.Split(' ')[2]);
int centerY = int.Parse(input.Split(' ')[3]);
int radius = int.Parse(input.Split(' ')[4]);
if (centerX - radius >= 0 & centerX + radius <= width &
centerY - radius >= 0 & centerY + radius <= height) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
|
[["-", 15, 16, 31, 16, 31, 16, 31, 16, 17, 47], ["+", 15, 16, 31, 16, 31, 16, 31, 16, 17, 20], ["-", 15, 16, 31, 16, 31, 16, 12, 16, 17, 18], ["+", 15, 16, 31, 16, 31, 16, 12, 16, 17, 19], ["-", 0, 57, 15, 16, 31, 16, 12, 16, 17, 47], ["+", 0, 57, 15, 16, 31, 16, 12, 16, 17, 20], ["-", 8, 196, 0, 57, 15, 16, 12, 16, 17, 18], ["+", 8, 196, 0, 57, 15, 16, 12, 16, 17, 19]]
| 8
| 172
| 8
|
using System;
namespace ConsoleApp2 {
class Program {
static void Main(string[] args) {
var A = Console.ReadLine().Split(' ');
int W = int.Parse(A[0]);
int H = int.Parse(A[1]);
int x = int.Parse(A[2]);
int y = int.Parse(A[3]);
int r = int.Parse(A[4]);
if (y - r > 0 && x - r > 0 && x > 0 && y > 0 && x + r <= W && y + r <= H) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
}
|
using System;
namespace ConsoleApp2 {
class Program {
static void Main(string[] args) {
var A = Console.ReadLine().Split(' ');
int W = int.Parse(A[0]);
int H = int.Parse(A[1]);
int x = int.Parse(A[2]);
int y = int.Parse(A[3]);
int r = int.Parse(A[4]);
if (y - r >= 0 && x - r >= 0 && x >= 0 && y >= 0 && x + r <= W &&
y + r <= H) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
}
|
[["-", 31, 16, 31, 16, 31, 16, 31, 16, 17, 47], ["+", 31, 16, 31, 16, 31, 16, 31, 16, 17, 20], ["-", 31, 16, 31, 16, 31, 16, 12, 16, 17, 47], ["+", 31, 16, 31, 16, 31, 16, 12, 16, 17, 20], ["-", 15, 16, 31, 16, 31, 16, 12, 16, 17, 47], ["+", 15, 16, 31, 16, 31, 16, 12, 16, 17, 20]]
| 8
| 160
| 8
|
using System;
using System.Linq;
namespace procon {
public class Program {
public static void Main(string[] args) {
var inputs = Console.ReadLine().Split().Select(int.Parse).ToArray();
var W = inputs[0];
var H = inputs[1];
var x = inputs[2];
var y = inputs[3];
var r = inputs[4];
// ????????????true
var left = r <= x;
var right = x + r <= W;
var top = y + r <= H;
var bottom = r <= y;
Console.WriteLine(left == right == top == bottom == true ? "Yes" : "No");
}
}
}
|
using System;
using System.Linq;
namespace procon {
public class Program {
public static void Main(string[] args) {
var inputs = Console.ReadLine().Split().Select(int.Parse).ToArray();
var W = inputs[0];
var H = inputs[1];
var x = inputs[2];
var y = inputs[3];
var r = inputs[4];
// ????????????true
var left = r <= x;
var right = x + r <= W;
var top = y + r <= H;
var bottom = r <= y;
Console.WriteLine(left && right && top && bottom ? "Yes" : "No");
}
}
}
|
[["-", 15, 16, 31, 16, 31, 16, 31, 16, 17, 60], ["+", 0, 41, 15, 16, 31, 16, 31, 16, 17, 98], ["-", 0, 41, 15, 16, 31, 16, 31, 16, 17, 60], ["+", 0, 28, 0, 41, 15, 16, 31, 16, 17, 98], ["-", 0, 28, 0, 41, 15, 16, 31, 16, 17, 60], ["+", 3, 4, 0, 28, 0, 41, 15, 16, 17, 98], ["-", 3, 4, 0, 28, 0, 41, 15, 16, 17, 60], ["-", 0, 28, 0, 41, 15, 16, 12, 211, 0, 146]]
| 8
| 149
| 8
|
using System;
public class SmallOrLarge {
//?????????????????§?°????????????????
static void Main(string[] args) {
/*---??£?¨???¨---*/
int W; //?????????????????¨??????????????¢????????????X??§?¨?
int H; //?????????????????¨??????????????¢????????????Y??§?¨?
int x; //??????X??§?¨?
int y; //??????Y??§?¨?
int r; //????????????
string[] num_unit;
bool flag = false;
/*---??£?¨???¨---*/
/*W???H???x???y???r ?????????????????????*/
num_unit = Console.ReadLine().Split(' ');
W = int.Parse(num_unit[0]);
H = int.Parse(num_unit[1]);
x = int.Parse(num_unit[2]);
y = int.Parse(num_unit[3]);
r = int.Parse(num_unit[4]);
/*??????????????¢???????????????????????????????????????*/
if (W <= (x - r)) {
if (H <= (y - r)) {
if (W >= (x + r)) {
if (H >= (y + r)) {
flag = true;
}
}
}
}
/*???????????????*/
if (flag == true) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
|
using System;
public class SmallOrLarge {
//?????????????????§?°????????????????
static void Main(string[] args) {
/*---??£?¨???¨---*/
int W; //?????????????????¨??????????????¢????????????X??§?¨?
int H; //?????????????????¨??????????????¢????????????Y??§?¨?
int x; //??????X??§?¨?
int y; //??????Y??§?¨?
int r; //????????????
string[] num_unit;
bool flag = false;
/*---??£?¨???¨---*/
/*W???H???x???y???r ?????????????????????*/
num_unit = Console.ReadLine().Split(' ');
W = int.Parse(num_unit[0]);
H = int.Parse(num_unit[1]);
x = int.Parse(num_unit[2]);
y = int.Parse(num_unit[3]);
r = int.Parse(num_unit[4]);
/*??????????????¢???????????????????????????????????????*/
if (0 <= (x - r)) {
if (0 <= (y - r)) {
if (W >= (x + r)) {
if (H >= (y + r)) {
flag = true;
}
}
}
}
/*???????????????*/
if (flag == true) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
|
[["-", 0, 195, 8, 196, 0, 57, 15, 16, 31, 22], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 31, 203], ["-", 0, 57, 64, 196, 0, 57, 15, 16, 31, 22], ["+", 0, 57, 64, 196, 0, 57, 15, 16, 31, 203]]
| 8
| 211
| 4
|
using System;
class Program {
static void Main(string[] args) {
int W, H, x, y, r;
string[] s = Console.ReadLine().Split(' ');
// int a = int.Parse(Console.ReadLine());
W = int.Parse(s[0]);
H = int.Parse(s[1]);
x = int.Parse(s[2]);
y = int.Parse(s[3]);
r = int.Parse(s[4]);
if (r < x && x < W - r && r < y && y < H - r) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
// Console.WriteLine("");
}
}
|
using System;
class Program {
static void Main(string[] args) {
int W, H, x, y, r;
string[] s = Console.ReadLine().Split(' ');
// int a = int.Parse(Console.ReadLine());
W = int.Parse(s[0]);
H = int.Parse(s[1]);
x = int.Parse(s[2]);
y = int.Parse(s[3]);
r = int.Parse(s[4]);
if (r <= x && x <= W - r && r <= y && y <= H - r) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
// Console.WriteLine("");
}
}
|
[["-", 15, 16, 31, 16, 31, 16, 31, 16, 17, 18], ["+", 15, 16, 31, 16, 31, 16, 31, 16, 17, 19], ["-", 15, 16, 31, 16, 31, 16, 12, 16, 17, 18], ["+", 15, 16, 31, 16, 31, 16, 12, 16, 17, 19], ["-", 0, 57, 15, 16, 31, 16, 12, 16, 17, 18], ["+", 0, 57, 15, 16, 31, 16, 12, 16, 17, 19], ["-", 8, 196, 0, 57, 15, 16, 12, 16, 17, 18], ["+", 8, 196, 0, 57, 15, 16, 12, 16, 17, 19]]
| 8
| 154
| 8
|
using System;
namespace AizuOnlineJudge {
class Program {
static void Main(string[] args) {
var array = Converter(Console.ReadLine());
Console.WriteLine(Calc(array));
Console.ReadLine();
}
static int[] Converter(string str) {
var array = str.Split(' ');
return Array.ConvertAll(array, int.Parse);
}
static string Calc(int[] array) {
var result = "No";
int W = array[0];
int H = array[1];
int x = array[2];
int y = array[3];
int r = array[4];
if ((x - r) > 0)
if ((x + r) < W)
if ((y - r) > 0)
if ((y + r) < H)
result = "Yes";
return result;
}
}
}
|
using System;
namespace AizuOnlineJudge {
class Program {
static void Main(string[] args) {
var array = Converter(Console.ReadLine());
Console.WriteLine(Calc(array));
Console.ReadLine();
}
static int[] Converter(string str) {
var array = str.Split(' ');
return Array.ConvertAll(array, int.Parse);
}
static string Calc(int[] array) {
var result = "No";
int W = array[0];
int H = array[1];
int x = array[2];
int y = array[3];
int r = array[4];
if ((x - r) >= 0)
if ((x + r) <= W)
if ((y - r) >= 0)
if ((y + r) <= H)
result = "Yes";
return result;
}
}
}
|
[["-", 0, 195, 8, 196, 0, 57, 15, 16, 17, 47], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 17, 20], ["-", 8, 196, 0, 57, 64, 57, 15, 16, 17, 18], ["+", 8, 196, 0, 57, 64, 57, 15, 16, 17, 19], ["-", 0, 57, 64, 57, 64, 57, 15, 16, 17, 47], ["+", 0, 57, 64, 57, 64, 57, 15, 16, 17, 20], ["-", 64, 57, 64, 57, 64, 57, 15, 16, 17, 18], ["+", 64, 57, 64, 57, 64, 57, 15, 16, 17, 19]]
| 8
| 192
| 8
|
using System;
using System.Linq;
class TestClass {
static void Main(string[] args) {
// W, H, x, y, r(半径)
int[] num = Console.ReadLine().Split().Select(a => int.Parse(a)).ToArray();
int W = num[0];
int H = num[1];
int x = num[2];
int y = num[3];
int r = num[4];
// x,yの位置が00~WH(半径込み)ならtrue
if (x < r || x > (W - r) || y < r || y > (H - r)) {
Console.WriteLine("NO");
} else {
Console.WriteLine("YES");
}
}
}
|
//コンパイル
// mcs ソース
//実行
// mono exe
using System;
using System.Linq;
class TestClass {
static void Main(string[] args) {
// W, H, x, y, r(半径)
int[] num = Console.ReadLine().Split().Select(a => int.Parse(a)).ToArray();
int W = num[0];
int H = num[1];
int x = num[2];
int y = num[3];
int r = num[4];
// x,yの位置が00~WH(半径込み)ならtrue
if (x < r || x > (W - r) || y < r || y > (H - r)) {
Console.WriteLine("No");
} else {
Console.WriteLine("Yes");
}
}
}
|
[["-", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222], ["+", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222]]
| 8
| 145
| 4
|
using System;
namespace AizuOnline {
class Program {
static void Main(string[] args) {
string[] inp = Console.ReadLine().Split();
int w = Int32.Parse(inp[0]);
int h = Int32.Parse(inp[1]);
int x = Int32.Parse(inp[2]);
int y = Int32.Parse(inp[3]);
int r = Int32.Parse(inp[4]);
string arranged = "Yes";
if (x < r && x > w - r) {
arranged = "No";
}
if (y < r && y > h - r) {
arranged = "No";
}
Console.WriteLine(arranged);
}
}
}
|
using System;
namespace AizuOnline {
class Program {
static void Main(string[] args) {
string[] inp = Console.ReadLine().Split();
int w = Int32.Parse(inp[0]);
int h = Int32.Parse(inp[1]);
int x = Int32.Parse(inp[2]);
int y = Int32.Parse(inp[3]);
int r = Int32.Parse(inp[4]);
string arranged = "Yes";
if (x < r || x > w - r) {
arranged = "No";
}
if (y < r || y > h - r) {
arranged = "No";
}
// Console.WriteLine("w={0} h={1} x={2} y={3} r={4}", w, h, x, y, r);
Console.WriteLine(arranged);
}
}
}
|
[["-", 0, 195, 8, 196, 0, 57, 15, 16, 17, 98], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 17, 106]]
| 8
| 156
| 4
|
using System;
class test {
static void Main() {
int w, h, x, y, r;
string[] str = Console.ReadLine().Split(' ');
w = int.Parse(str[0]);
h = int.Parse(str[1]);
x = int.Parse(str[2]);
y = int.Parse(str[3]);
r = int.Parse(str[4]);
if (x - r >= 0 || x + r <= w || y - r >= 0 || y - r <= h) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
|
using System;
class test {
static void Main() {
int w, h, x, y, r;
string[] str = Console.ReadLine().Split(' ');
w = int.Parse(str[0]);
h = int.Parse(str[1]);
x = int.Parse(str[2]);
y = int.Parse(str[3]);
r = int.Parse(str[4]);
if (x - r >= 0 && x + r <= w && y - r >= 0 && y + r <= h) {
Console.WriteLine("Yes");
} else {
Console.WriteLine("No");
}
}
}
|
[["-", 0, 57, 15, 16, 31, 16, 31, 16, 17, 106], ["+", 0, 57, 15, 16, 31, 16, 31, 16, 17, 98], ["-", 8, 196, 0, 57, 15, 16, 31, 16, 17, 106], ["+", 8, 196, 0, 57, 15, 16, 31, 16, 17, 98], ["-", 0, 195, 8, 196, 0, 57, 15, 16, 17, 106], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 17, 98], ["-", 0, 57, 15, 16, 12, 16, 31, 16, 17, 33], ["+", 0, 57, 15, 16, 12, 16, 31, 16, 17, 72]]
| 8
| 152
| 8
|
using System;
class Program {
static void Main() {
string[] s = Console.ReadLine().Split(' ');
// 0:W, 1:H, 2:x, 3:y, 4:r
int[] i = new int[s.Length];
for (int j = 0; j < s.Length; j++)
i[j] = int.Parse(s[j]);
String ret = "";
if (((i[2] - i[4]) >= 0 && (i[3] + i[4]) <= i[1]) ||
((i[3] - i[4]) >= 0 && (i[2] + i[4]) <= i[0]))
ret = "Yes";
else
ret = "No";
Console.WriteLine(ret);
}
}
|
using System;
class Program {
static void Main() {
string[] s = Console.ReadLine().Split(' ');
// 0:W, 1:H, 2:x, 3:y, 4:r
int[] i = new int[s.Length];
for (int j = 0; j < s.Length; j++)
i[j] = int.Parse(s[j]);
String ret = "";
if (((i[2] - i[4]) >= 0 && (i[3] + i[4]) <= i[1]) &&
((i[3] - i[4]) >= 0 && (i[2] + i[4]) <= i[0]))
ret = "Yes";
else
ret = "No";
Console.WriteLine(ret);
}
}
|
[["-", 0, 195, 8, 196, 0, 57, 15, 16, 17, 106], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 17, 98]]
| 8
| 171
| 2
|
using System;
namespace ConsoleApp1 {
class Program {
static void Main(string[] args) {
int W, H, x, y, r;
string[] str = Console.ReadLine().Split(' ');
W = int.Parse(str[0]);
H = int.Parse(str[1]);
x = int.Parse(str[2]);
y = int.Parse(str[3]);
r = int.Parse(str[4]);
if (x - r >= 0 || x + r <= W || y - r >= 0 || y + r <= H)
Console.WriteLine("Yes");
else
Console.WriteLine("No");
}
}
}
|
using System;
namespace ConsoleApp1 {
class Program {
static void Main(string[] args) {
int W, H, x, y, r;
string[] str = Console.ReadLine().Split(' ');
W = int.Parse(str[0]);
H = int.Parse(str[1]);
x = int.Parse(str[2]);
y = int.Parse(str[3]);
r = int.Parse(str[4]);
if (x - r >= 0 && x + r <= W && y - r >= 0 && y + r <= H)
Console.WriteLine("Yes");
else
Console.WriteLine("No");
}
}
}
|
[["-", 0, 57, 15, 16, 31, 16, 31, 16, 17, 106], ["+", 0, 57, 15, 16, 31, 16, 31, 16, 17, 98], ["-", 8, 196, 0, 57, 15, 16, 31, 16, 17, 106], ["+", 8, 196, 0, 57, 15, 16, 31, 16, 17, 98], ["-", 0, 195, 8, 196, 0, 57, 15, 16, 17, 106], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 17, 98]]
| 8
| 156
| 6
|
using System;
namespace AOJ.intro {
namespace ITP_1_2_D {
public static class CircleInRectangle {
public static void Main() {
// [W, H, x, y, r]
string[] circleElements = Console.ReadLine().Split();
int W, H, x, y, r;
W = int.Parse(circleElements[0]);
H = int.Parse(circleElements[1]);
x = int.Parse(circleElements[2]);
y = int.Parse(circleElements[3]);
r = int.Parse(circleElements[4]);
// ロジック
// 水平方向: x - r < 0, x + r > W → OUT
// 鉛直方向: y - r < 0, y + r > H → OUT
if (x - r < 0 || x + r > W) {
Console.WriteLine("No");
} else if (y - r < 0 || y + r > H) {
Console.WriteLine("No");
} else if (x - r > 0 && x + r < W && y - r > 0 && y + r < H) {
Console.WriteLine("Yes");
}
}
}
}
}
|
using System;
namespace AOJ.intro {
namespace ITP_1_2_D {
public static class CircleInRectangle {
public static void Main() {
// [W, H, x, y, r]
string[] circleElements = Console.ReadLine().Split();
int W, H, x, y, r;
W = int.Parse(circleElements[0]);
H = int.Parse(circleElements[1]);
x = int.Parse(circleElements[2]);
y = int.Parse(circleElements[3]);
r = int.Parse(circleElements[4]);
// ロジック
// 水平方向: x - r < 0, x + r > W → OUT
// 鉛直方向: y - r < 0, y + r > H → OUT
if (x - r < 0 || x + r > W) {
Console.WriteLine("No");
} else if (y - r < 0 || y + r > H) {
Console.WriteLine("No");
} else if (x - r >= 0 && x + r <= W && y - r >= 0 && y + r <= H) {
Console.WriteLine("Yes");
}
}
}
}
}
|
[["-", 15, 16, 31, 16, 31, 16, 31, 16, 17, 47], ["+", 15, 16, 31, 16, 31, 16, 31, 16, 17, 20], ["-", 15, 16, 31, 16, 31, 16, 12, 16, 17, 18], ["+", 15, 16, 31, 16, 31, 16, 12, 16, 17, 19], ["-", 75, 57, 15, 16, 31, 16, 12, 16, 17, 47], ["+", 75, 57, 15, 16, 31, 16, 12, 16, 17, 20], ["-", 75, 57, 75, 57, 15, 16, 12, 16, 17, 18], ["+", 75, 57, 75, 57, 15, 16, 12, 16, 17, 19]]
| 8
| 206
| 8
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace PrintTestCases {
class Program {
static void Main(string[] args) {
int i = 0;
do {
int a = int.Parse(Console.ReadLine());
if (a == 0) {
break;
}
Console.WriteLine("Case {0}: {1}", i + 1, a);
} while (true);
}
}
}
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace PrintTestCases {
class Program {
static void Main(string[] args) {
int i = 0;
do {
int a = int.Parse(Console.ReadLine());
if (a == 0) {
break;
}
Console.WriteLine("Case {0}: {1}", i + 1, a);
i++;
} while (true);
}
}
}
|
[["+", 0, 82, 8, 196, 0, 1, 0, 223, 0, 22], ["+", 0, 82, 8, 196, 0, 1, 0, 223, 0, 29], ["+", 8, 196, 0, 82, 8, 196, 0, 1, 0, 35]]
| 8
| 98
| 3
|
using System;
class Program {
static void Main() {
var count = 1;
var i = 1;
while (i != 0) {
i = int.Parse(Console.ReadLine());
Console.WriteLine("Case {0}: {1}", count, i);
count++;
}
}
}
|
using System;
class Program {
static void Main() {
var count = 1;
var i = 1;
while (i != 0) {
i = int.Parse(Console.ReadLine());
if (i != 0)
Console.WriteLine("Case {0}: {1}", count, i);
count++;
}
}
}
|
[["+", 8, 196, 0, 52, 8, 196, 0, 57, 0, 121], ["+", 8, 196, 0, 52, 8, 196, 0, 57, 0, 24], ["+", 0, 52, 8, 196, 0, 57, 15, 16, 31, 22], ["+", 0, 52, 8, 196, 0, 57, 15, 16, 17, 79], ["+", 0, 52, 8, 196, 0, 57, 15, 16, 12, 203], ["+", 8, 196, 0, 52, 8, 196, 0, 57, 0, 25]]
| 8
| 61
| 6
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Print_Test_Cases {
class Program {
static void Main(string[] args) {
List<int> input = new List<int>();
while (true) {
int temp = int.Parse(Console.ReadLine());
if (temp == 0) {
break;
}
input.Add(temp);
}
for (int i = 0; i < input.Count; ++i) {
Console.WriteLine("Case " + i + ":" + " " + input[i]);
}
}
}
}
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Print_Test_Cases {
class Program {
static void Main(string[] args) {
List<int> input = new List<int>();
while (true) {
int temp = int.Parse(Console.ReadLine());
if (temp == 0) {
break;
}
input.Add(temp);
}
for (int i = 0; i < input.Count; ++i) {
Console.WriteLine("Case " + (i + 1) + ":" + " " + input[i]);
}
}
}
}
|
[["+", 31, 16, 31, 16, 31, 16, 12, 23, 0, 24], ["+", 31, 16, 31, 16, 12, 23, 0, 16, 17, 72], ["+", 31, 16, 31, 16, 12, 23, 0, 16, 12, 203], ["+", 31, 16, 31, 16, 31, 16, 12, 23, 0, 25]]
| 8
| 139
| 4
|
using System;
namespace _3_2b {
class Program {
static void Main(string[] args) {
int piyo = 0;
string[] hoge = new string[10000];
int[] nya = new int[10000];
// Console.ReadLine();
for (int i = 0;; i++) {
nya[i] = int.Parse(Console.ReadLine());
if (nya[i] == 0) {
piyo = i;
break;
}
// Console.WriteLine("Case {0}: {1}", i,
// Console.ReadLine());//なんか毎行実行しちゃう→解決?たぶんifのReadLineが実行されて0がとばされ無限ループだった。
}
for (int j = 0; j < piyo;
j++) //真ん中条件 int.Parse(hoge[j]) != 0だと無限ループフリーズの闇
{
Console.WriteLine("Case {0}: {1}", j, nya[j]);
}
}
}
}
|
using System;
namespace _3_2b {
class Program {
static void Main(string[] args) {
int piyo = 0;
string[] hoge = new string[100000];
int[] nya = new int[100000];
// Console.ReadLine();
for (int i = 0;; i++) {
nya[i] = int.Parse(Console.ReadLine());
if (nya[i] == 0) {
piyo = i;
break;
}
// Console.WriteLine("Case {0}: {1}", i,
// Console.ReadLine());//なんか毎行実行しちゃう→解決?たぶんifのReadLineが実行されて0がとばされ無限ループだった。
}
for (int j = 0; j < piyo;
j++) //真ん中条件 int.Parse(hoge[j]) != 0だと無限ループフリーズの闇
{
Console.WriteLine("Case {0}: {1}", j + 1, nya[j]);
}
}
}
}
|
[["-", 0, 212, 0, 227, 39, 224, 225, 226, 0, 203], ["+", 0, 212, 0, 227, 39, 224, 225, 226, 0, 203], ["+", 0, 213, 3, 4, 0, 28, 0, 16, 17, 72], ["+", 0, 213, 3, 4, 0, 28, 0, 16, 12, 203]]
| 8
| 131
| 6
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace _1_1_a {
class Program {
static void Main() {
for (int i = 1; i > 0; i++) {
int x = int.Parse(Console.ReadLine());
if (x == 0)
break;
else
Console.WriteLine("Case{0}:{1}", i, x);
}
}
}
}
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace _1_1_a {
class Program {
static void Main() {
for (int i = 1; i > 0; i++) {
int x = int.Parse(Console.ReadLine());
if (x == 0)
break;
else
Console.WriteLine("Case {0}: {1}", i, x);
}
}
}
}
|
[["-", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222], ["+", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222]]
| 8
| 94
| 2
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace AOJHelloWorld1 {
class Program {
static void Main(string[] args) {
for (int i = 0; i > 0; i++) {
int x = int.Parse(Console.ReadLine());
if (x == 0)
break;
else
Console.WriteLine("Case {0}: {1}", i, x);
}
}
}
}
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace AOJHelloWorld1 {
class Program {
static void Main(string[] args) {
for (int i = 1; i > 0; i++) {
int x = int.Parse(Console.ReadLine());
if (x == 0)
break;
else {
Console.WriteLine("Case {0}: {1}", i, x);
}
}
}
}
}
|
[["-", 0, 7, 10, 198, 0, 200, 0, 212, 0, 203], ["+", 0, 7, 10, 198, 0, 200, 0, 212, 0, 203], ["+", 0, 7, 8, 196, 0, 57, 75, 196, 0, 45], ["+", 0, 7, 8, 196, 0, 57, 75, 196, 0, 46]]
| 8
| 98
| 4
|
using System;
class Program {
static void Main(string[] args) {
int count = 1;
string data;
while (true) {
data = Console.ReadLine();
if (data == "0") {
break;
}
Console.WriteLine("Case " + count.ToString() + ": " + data);
}
}
}
|
using System;
class Program {
static void Main(string[] args) {
int count = 1;
string data;
while (true) {
data = Console.ReadLine();
if (data == "0") {
break;
}
Console.WriteLine("Case " + count.ToString() + ": " + data);
count++;
}
}
}
|
[["+", 0, 52, 8, 196, 0, 1, 0, 223, 0, 22], ["+", 0, 52, 8, 196, 0, 1, 0, 223, 0, 29], ["+", 8, 196, 0, 52, 8, 196, 0, 1, 0, 35]]
| 8
| 73
| 3
|
using System;
namespace PrintTestCases {
class Program {
static void Main(string[] args) {
for (int i = 0;; i++) {
string str = Console.ReadLine();
int input = int.Parse(str);
if (input == 0)
break;
Console.WriteLine("Case {0}: {1}", i, input);
}
}
}
}
|
using System;
namespace PrintTestCases {
class Program {
static void Main(string[] args) {
for (int i = 0;; i++) {
string str = Console.ReadLine();
int input = int.Parse(str);
if (input == 0)
break;
Console.WriteLine("Case {0}: {1}", i + 1, input);
}
}
}
}
|
[["+", 0, 213, 3, 4, 0, 28, 0, 16, 17, 72], ["+", 0, 213, 3, 4, 0, 28, 0, 16, 12, 203]]
| 8
| 75
| 2
|
using System;
namespace PrintTestCases {
class Program {
static void Main(string[] args) {
for (int i = 0;; i++) {
string str = Console.ReadLine();
int input = int.Parse(str);
if (input == 0)
break;
Console.WriteLine("Case {0}: {1}", i, input);
}
}
}
}
|
using System;
namespace PrintTestCases {
class Program {
static void Main(string[] args) {
for (int i = 1;; i++) {
string str = Console.ReadLine();
int input = int.Parse(str);
if (input == 0)
break;
Console.WriteLine("Case {0}: {1}", i, input);
}
}
}
}
|
[["-", 0, 7, 10, 198, 0, 200, 0, 212, 0, 203], ["+", 0, 7, 10, 198, 0, 200, 0, 212, 0, 203]]
| 8
| 75
| 2
|
public partial class IntroductionToProgramming {
public static void Main() {
string str = System.Console.ReadLine();
decimal i = 1;
while (str != "0") {
System.Console.WriteLine("Case " + i++.ToString() + " " + str);
str = System.Console.ReadLine();
}
}
}
|
public partial class IntroductionToProgramming {
public static void Main() {
string str = System.Console.ReadLine();
decimal i = 1;
while (str != "0") {
System.Console.WriteLine("Case " + i++.ToString() + ": " + str);
str = System.Console.ReadLine();
}
}
}
|
[["-", 0, 28, 0, 16, 31, 16, 12, 5, 0, 222], ["+", 0, 28, 0, 16, 31, 16, 12, 5, 0, 222]]
| 8
| 74
| 2
|
using System;
using System.Collections.Generic;
using System.Text;
namespace ConsoleApplication2 {
class Program {
static void Main(string[] args) {
// string[] s =Console.ReadLine().Split(',');
// int w = int.Parse(s[0]);
List<string> stringList = new List<string>();
int count = 0;
for (int i = 0;; i++) {
string x = Console.ReadLine();
if (x == "0")
break;
stringList.Add(x);
}
foreach (string j in stringList) {
Console.WriteLine("Case " + count + ": " + j);
}
// int n =int.Parse(s);
}
}
}
|
using System;
using System.Collections.Generic;
using System.Text;
namespace ConsoleApplication2 {
class Program {
static void Main(string[] args) {
// string[] s =Console.ReadLine().Split(',');
// int w = int.Parse(s[0]);
List<string> stringList = new List<string>();
int count = 1;
for (int i = 0;; i++) {
string x = Console.ReadLine();
if (x == "0")
break;
stringList.Add(x);
}
foreach (string j in stringList) {
Console.WriteLine("Case " + count + ": " + j);
count++;
}
// int n =int.Parse(s);
}
}
}
|
[["-", 0, 197, 0, 198, 0, 200, 0, 212, 0, 203], ["+", 0, 197, 0, 198, 0, 200, 0, 212, 0, 203], ["+", 8, 196, 0, 210, 8, 196, 0, 1, 0, 35], ["+", 0, 210, 8, 196, 0, 1, 0, 223, 0, 22], ["+", 0, 210, 8, 196, 0, 1, 0, 223, 0, 29]]
| 8
| 121
| 5
|
using System;
using System.Collections.Generic;
using System.Text;
namespace ConsoleApplication3 {
class Program {
static void Main(string[] args) {
int n = 1;
while (true) {
string s = Console.ReadLine();
if (s == "0") {
break;
}
Console.WriteLine("Case" + n + ": " + s);
n = n++;
}
// for (int i = 0; i < 1000; i++)
//{
// Console.WriteLine("Hello World"); }
}
}
}
|
using System;
using System.Collections.Generic;
using System.Text;
namespace ConsoleApplication3 {
class Program {
static void Main(string[] args) {
int n = 1;
while (true) {
string s = Console.ReadLine();
if (s == "0") {
break;
}
Console.WriteLine("Case " + n + ": " + s);
n++;
}
// for (int i = 0; i < 1000; i++)
//{
// Console.WriteLine("Hello World"); }
}
}
}
|
[["-", 0, 16, 31, 16, 31, 16, 31, 5, 0, 222], ["+", 0, 16, 31, 16, 31, 16, 31, 5, 0, 222], ["-", 0, 52, 8, 196, 0, 1, 0, 11, 31, 22], ["-", 8, 196, 0, 1, 0, 11, 0, 202, 0, 32]]
| 8
| 91
| 4
|
using System;
using System.Collections.Generic;
using System.Text;
namespace ConsoleApplication7 {
class Program {
static void Main(string[] args) {
int n = 1;
while (true) {
string s = Console.ReadLine();
if (s == "0") {
break;
}
Console.WriteLine("Case " + n + " :" + s);
n++;
}
}
}
}
|
using System;
using System.Collections.Generic;
using System.Text;
namespace ConsoleApplication7 {
class Program {
static void Main(string[] args) {
int n = 1;
while (true) {
string s = Console.ReadLine();
if (s == "0") {
break;
}
Console.WriteLine("Case " + n + ": " + s);
n++;
}
}
}
}
|
[["-", 0, 28, 0, 16, 31, 16, 12, 5, 0, 222], ["+", 0, 28, 0, 16, 31, 16, 12, 5, 0, 222]]
| 8
| 86
| 2
|
using System;
using System.Collections.Generic;
using System.Text;
namespace ConsoleApplication9 {
class Program {
static void Main(string[] args) {
String str = Console.ReadLine();
int x = int.Parse(str);
int i = 0;
while (x != 0) {
i++;
Console.WriteLine("Case" + i + ":" + x);
str = Console.ReadLine();
x = int.Parse(str);
}
}
}
}
|
using System;
using System.Collections.Generic;
using System.Text;
namespace ConsoleApplication9 {
class Program {
static void Main(string[] args) {
String str = Console.ReadLine();
int x = int.Parse(str);
int i = 0;
while (x != 0) {
i++;
Console.WriteLine("Case " + i + ": " + x);
str = Console.ReadLine();
x = int.Parse(str);
}
}
}
}
|
[["-", 0, 16, 31, 16, 31, 16, 31, 5, 0, 222], ["+", 0, 16, 31, 16, 31, 16, 31, 5, 0, 222], ["-", 0, 28, 0, 16, 31, 16, 12, 5, 0, 222], ["+", 0, 28, 0, 16, 31, 16, 12, 5, 0, 222]]
| 8
| 103
| 4
|
using System;
using System.Collections.Generic;
class Program {
public void Proc() {
bool mustRead = true;
int idx = 1;
while (mustRead) {
int num = int.Parse(Console.ReadLine());
if (num == 0) {
mustRead = false;
break;
}
Console.WriteLine("Case " + idx + ":" + num);
idx++;
}
}
static void Main(string[] args)
{
Program prg = new Program();
prg.Proc();
}
}
|
using System;
using System.Collections.Generic;
class Program {
public void Proc() {
bool mustRead = true;
int idx = 1;
while (mustRead) {
int num = int.Parse(Console.ReadLine());
if (num == 0) {
mustRead = false;
break;
}
Console.WriteLine("Case " + idx + ": " + num);
idx++;
}
}
static void Main(string[] args)
{
Program prg = new Program();
prg.Proc();
}
}
|
[["-", 0, 28, 0, 16, 31, 16, 12, 5, 0, 222], ["+", 0, 28, 0, 16, 31, 16, 12, 5, 0, 222]]
| 8
| 110
| 2
|
using System;
class main {
public static void Main() {
bool isEnd = false;
int caseNum = 1;
while (isEnd == false) {
string input = Console.ReadLine();
int x = int.Parse(input);
if (x != 0)
Console.WriteLine("Case " + caseNum + ":" + x);
else
isEnd = true;
caseNum++;
}
}
}
|
using System;
class main {
public static void Main() {
bool isEnd = false;
int caseNum = 1;
while (isEnd == false) {
string input = Console.ReadLine();
int x = int.Parse(input);
if (x != 0)
Console.WriteLine("Case " + caseNum + ": " + x);
else
isEnd = true;
caseNum++;
}
}
}
|
[["-", 0, 28, 0, 16, 31, 16, 12, 5, 0, 222], ["+", 0, 28, 0, 16, 31, 16, 12, 5, 0, 222]]
| 8
| 83
| 2
|
using System;
using System.Collections.Generic;
class Program {
static void Main(string[] args) {
int count = 1;
while (true) {
int num = int.Parse(Console.ReadLine());
if (num == 0) {
break;
}
Console.WriteLine("Case {0}: {1}", count, num);
}
}
}
|
using System;
using System.Collections.Generic;
class Program {
static void Main(string[] args) {
int count = 1;
while (true) {
int num = int.Parse(Console.ReadLine());
if (num == 0) {
break;
}
Console.WriteLine("Case {0}: {1}", count, num);
count++;
}
}
}
|
[["+", 0, 52, 8, 196, 0, 1, 0, 223, 0, 22], ["+", 0, 52, 8, 196, 0, 1, 0, 223, 0, 29], ["+", 8, 196, 0, 52, 8, 196, 0, 1, 0, 35]]
| 8
| 73
| 3
|
using System;
using System.Collections.Generic;
namespace ConsoleApplication10 {
class Program {
static void Main(string[] args) {
int i = 1;
while (true) {
string str = Console.ReadLine();
int x = int.Parse(str);
if (x == 0) {
break;
}
Console.WriteLine("Case {0}:{1}", i, x);
i++;
}
}
}
}
|
using System;
using System.Collections.Generic;
namespace ConsoleApplication10 {
class Program {
static void Main(string[] args) {
int i = 1;
while (true) {
string str = Console.ReadLine();
int x = int.Parse(str);
if (x == 0) {
break;
}
Console.WriteLine("Case {0}: {1}", i, x);
i++;
}
}
}
}
|
[["-", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222], ["+", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222]]
| 8
| 85
| 2
|
using System;
using System.Collections;
namespace PrintTestCases {
class PrintTestCases {
static void Main() {
int tmp;
int i = 0;
ArrayList data = new ArrayList();
while (true) {
tmp = int.Parse(Console.ReadLine());
if (tmp == 0)
break;
data.Add(tmp);
}
for (i = 0; i < data.Count; i++) {
Console.WriteLine("Case " + (i + 1) + ":" + data[i]);
}
}
}
}
|
using System;
using System.Collections;
namespace PrintTestCases {
class PrintTestCases {
static void Main() {
int tmp;
int i = 0;
ArrayList data = new ArrayList();
while (true) {
tmp = int.Parse(Console.ReadLine());
if (tmp == 0)
break;
data.Add(tmp);
}
for (i = 0; i < data.Count; i++) {
Console.WriteLine("Case " + (i + 1) + ": " + data[i]);
}
}
}
}
|
[["-", 0, 28, 0, 16, 31, 16, 12, 5, 0, 222], ["+", 0, 28, 0, 16, 31, 16, 12, 5, 0, 222]]
| 8
| 114
| 2
|
using System;
class Program {
static void Main(string[] args) {
Input CInput = new Input();
int[] input = new int[(int)Input.Define.MAX_ArraySize];
int num = 0;
input = CInput.Multiline_int(ref num);
for (int i = 0; i < num; i++) {
Console.WriteLine("Case {0}: {1} ", i, input[i]);
}
}
class Input {
public enum Define { MAX_ArraySize = 1000000 }
public string Line1_string() { return Console.ReadLine(); }
public int Line1_int() {
var input = Console.ReadLine();
return int.Parse(input);
}
public int[] Line1_int(int chr, int num) {
var input = Console.ReadLine();
var split = input.Split(' ');
int[] spliti = new int[10];
for (int i = 0; i < num; i++) {
spliti[i] = int.Parse(split[i]);
}
return spliti;
}
public int[] Multiline_int(ref int num) {
int i = 0;
int[] data = new int[(int)Input.Define.MAX_ArraySize];
while (true) {
var input = Console.ReadLine();
var value = int.Parse(input);
if (value == 0)
break;
data[i] = value;
i++;
}
num = i;
return data;
}
}
}
|
using System;
class Program {
static void Main(string[] args) {
Input CInput = new Input();
int[] input = new int[(int)Input.Define.MAX_ArraySize];
int num = 0;
input = CInput.Multiline_int(ref num);
for (int i = 0; i < num; i++) {
Console.WriteLine("Case {0}: {1}", i + 1, input[i]);
}
}
class Input {
public enum Define { MAX_ArraySize = 1000000 }
public string Line1_string() { return Console.ReadLine(); }
public int Line1_int() {
var input = Console.ReadLine();
return int.Parse(input);
}
public int[] Line1_int(int chr, int num) {
var input = Console.ReadLine();
var split = input.Split(' ');
int[] spliti = new int[10];
for (int i = 0; i < num; i++) {
spliti[i] = int.Parse(split[i]);
}
return spliti;
}
public int[] Multiline_int(ref int num) {
int i = 0;
int[] data = new int[(int)Input.Define.MAX_ArraySize];
while (true) {
var input = Console.ReadLine();
var value = int.Parse(input);
if (value == 0)
break;
data[i] = value;
i++;
}
num = i;
return data;
}
}
}
|
[["-", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222], ["+", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222], ["+", 0, 213, 3, 4, 0, 28, 0, 16, 17, 72], ["+", 0, 213, 3, 4, 0, 28, 0, 16, 12, 203]]
| 8
| 306
| 4
|
using System;
class Program {
static void Main() {
for (int i = 1; i > 0; i++) {
int x = int.Parse(Console.ReadLine());
if (x == 0)
break;
Console.WriteLine("Case {0}:{1}", i, x);
}
}
}
|
using System;
class Program {
static void Main() {
for (int i = 1; i > 0; i++) {
int x = int.Parse(Console.ReadLine());
if (x == 0)
break;
Console.WriteLine("Case {0}: {1}", i, x);
}
}
}
|
[["-", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222], ["+", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222]]
| 8
| 65
| 2
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace ConsoleApplication6 {
class Program {
static void Main(string[] args) {
{
var b = 0;
while (true) {
var ab = Console.ReadLine().Split().Select(int.Parse).ToArray();
var a = ab[0];
if (a == 0)
break;
b++;
Console.WriteLine("Case {0}:{1}", b, ab[0]);
}
}
}
}
}
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace ConsoleApplication6 {
class Program {
static void Main(string[] args) {
{
var b = 0;
while (true) {
var ab = Console.ReadLine().Split().Select(long.Parse).ToArray();
var a = ab[0];
if (a == 0)
break;
b++;
Console.WriteLine("Case {0}: {1}", b, ab[0]);
}
}
}
}
}
|
[["-", 205, 213, 3, 4, 0, 28, 0, 214, 205, 199], ["+", 205, 213, 3, 4, 0, 28, 0, 214, 205, 199], ["-", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222], ["+", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222]]
| 8
| 111
| 4
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace ConsoleApp8 {
class Program {
static void Main(string[] args) {
List<int> a = new List<int>();
while (true) {
string i = Console.ReadLine();
if (i == "0")
break;
a.Add(int.Parse(i));
}
for (int i = 0; i < a.Count; i++) {
Console.WriteLine("Case{0}: {1}", i + 1, a[i]);
}
}
}
}
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace ConsoleApp8 {
class Program {
static void Main(string[] args) {
List<int> a = new List<int>();
while (true) {
string i = Console.ReadLine();
if (i == "0")
break;
a.Add(int.Parse(i));
}
for (int i = 0; i < a.Count; i++) {
Console.WriteLine("Case {0}: {1}", i + 1, a[i]);
}
}
}
}
|
[["-", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222], ["+", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222]]
| 8
| 126
| 2
|
using System;
using System.Collections.Generic;
class MainClass {
public static void Main(string[] args) {
List<int> input = new List<int>(10000);
int tmp = 0;
while (true) {
tmp = Convert.ToInt32(Console.ReadLine());
if (tmp == 0)
break;
input.Add(tmp);
}
for (int i = 0; i < input.Count; i++) {
Console.WriteLine("Case {0}: {1}", i, input[i]);
}
}
}
|
using System;
using System.Collections.Generic;
class MainClass {
public static void Main(string[] args) {
List<int> input = new List<int>(10000);
int tmp = 0;
while (true) {
tmp = Convert.ToInt32(Console.ReadLine());
if (tmp == 0)
break;
input.Add(tmp);
}
for (int i = 0; i < input.Count; i++) {
Console.WriteLine("Case {0}: {1}", i + 1, input[i]);
}
}
}
|
[["+", 0, 213, 3, 4, 0, 28, 0, 16, 17, 72], ["+", 0, 213, 3, 4, 0, 28, 0, 16, 12, 203]]
| 8
| 114
| 2
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace ConsoleApplication4 {
class Program {
static void Main(string[] args) {
/*string sss = Console.ReadLine();
string[] str = sss.Split(' ');
int a = int.Parse(str[0]);*/
var a = 1;
while (true) {
var b = int.Parse(Console.ReadLine());
if (b == 0) {
break;
}
Console.WriteLine("Case {0}: {1}", a, b);
b++;
}
}
}
}
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace ConsoleApplication4 {
class Program {
static void Main(string[] args) {
var a = 1;
while (true) {
var b = int.Parse(Console.ReadLine());
if (b == 0) {
break;
}
Console.WriteLine("Case {0}: {1}", a, b);
a++;
}
}
}
}
|
[["-", 0, 52, 8, 196, 0, 1, 0, 223, 0, 22], ["+", 0, 52, 8, 196, 0, 1, 0, 223, 0, 22]]
| 8
| 91
| 2
|
using System;
namespace CA {
class Prg {
static void Main() {
string str;
int i = 0;
while (true) {
if ((str = Console.ReadLine()) != "0")
break;
Console.WriteLine("Case " + ++i + ": " + str);
}
}
}
}
|
using System;
namespace CA {
class Prg {
static void Main() {
string str;
int i = 0;
while (true) {
if ((str = Console.ReadLine()) == "0")
break;
Console.WriteLine("Case " + ++i + ": " + str);
}
}
}
}
|
[["-", 0, 52, 8, 196, 0, 57, 15, 16, 17, 79], ["+", 0, 52, 8, 196, 0, 57, 15, 16, 17, 60]]
| 8
| 68
| 2
|
using System;
namespace ITP1_3_B {
class Program {
static void Main(string[] args) {
for (int j = 1; j < 10001; j++) {
long num = long.Parse(Console.ReadLine());
if (num == 0)
break;
Console.WriteLine("case {0}: {1}", j, num);
}
}
}
}
|
using System;
namespace ITP1_3_B {
class Program {
static void Main(string[] args) {
for (int j = 1; j < 10001; j++) {
long num = long.Parse(Console.ReadLine());
if (num == 0)
break;
Console.WriteLine("Case {0}: {1}", j, num);
}
}
}
}
|
[["-", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222], ["+", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222]]
| 8
| 73
| 2
|
using System;
using System.Collections.Generic;
using System.Collections;
// using System.Linq;
// using System.Text;
// using System.Threading.Tasks;
// namespace _1_A
//{
class Program {
static void Main(string[] args) {
ArrayList array = new ArrayList();
int i;
string x = Console.ReadLine();
int z = int.Parse(x);
for (i = 0; i < 10000; i++) {
if (z != 0) {
array.Add(z);
x = Console.ReadLine();
z = int.Parse(x);
} else
break;
}
int k = 1;
foreach (object obj in array) {
Console.WriteLine("Case" + k + ":" + " " + obj.ToString());
k++;
}
// Console.Read();
}
}
//}
|
using System;
using System.Collections.Generic;
using System.Collections;
// using System.Linq;
// using System.Text;
// using System.Threading.Tasks;
// namespace _1_A
//{
class Program {
static void Main(string[] args) {
ArrayList array = new ArrayList();
int i;
string x = Console.ReadLine();
int z = int.Parse(x);
for (i = 0; i < 10000; i++) {
if (z != 0) {
array.Add(z);
x = Console.ReadLine();
z = int.Parse(x);
} else
break;
}
int k = 1;
foreach (object obj in array) {
Console.WriteLine("Case" + " " + k + ":" + " " + obj.ToString());
k++;
}
// Console.Read();
}
}
//}
|
[["+", 31, 16, 31, 16, 31, 16, 12, 5, 0, 62], ["+", 31, 16, 31, 16, 31, 16, 12, 5, 0, 222], ["+", 0, 16, 31, 16, 31, 16, 31, 16, 17, 72]]
| 8
| 159
| 4
|
using System;
class hoge {
static void Main() {
int i = 0;
string input;
bool notZero = true;
while (notZero) {
i += 1;
input = Console.ReadLine();
if (input == "0") {
Console.WriteLine("Case {0}: {1}", i, input);
} else {
notZero = false;
}
}
}
}
|
using System;
class hoge {
static void Main() {
int i = 0;
string input;
bool notZero = true;
while (notZero) {
i += 1;
input = Console.ReadLine();
if (input != "0") {
Console.WriteLine("Case {0}: {1}", i, input);
} else {
notZero = false;
}
}
}
}
|
[["-", 0, 52, 8, 196, 0, 57, 15, 16, 17, 60], ["+", 0, 52, 8, 196, 0, 57, 15, 16, 17, 79]]
| 8
| 75
| 2
|
using System;
namespace ConsoleApp9 {
class Program {
static void Main(string[] args) {
for (int a = 1; a <= 10000; a++) {
string B = Console.ReadLine();
int b = int.Parse(B);
if (b == 0) {
break;
} else {
Console.WriteLine("case " + a + ": " + b);
}
}
}
}
}
|
using System;
namespace ConsoleApp9 {
class Program {
static void Main(string[] args) {
for (int a = 1; a <= 10000; a++) {
string B = Console.ReadLine();
int b = int.Parse(B);
if (b == 0) {
break;
} else {
Console.WriteLine("Case " + a + ": " + b);
}
}
}
}
}
|
[["-", 0, 16, 31, 16, 31, 16, 31, 5, 0, 222], ["+", 0, 16, 31, 16, 31, 16, 31, 5, 0, 222]]
| 8
| 87
| 2
|
using System;
public class Hello {
public static void Main() {
int count = 0;
string s = string.Empty;
while ((s = Console.ReadLine()) != "0") {
Console.WriteLine("Case {0}: {1}", count, s);
count++;
}
}
}
|
using System;
public class Hello {
public static void Main() {
int count = 1;
string s = string.Empty;
while ((s = Console.ReadLine()) != "0") {
Console.WriteLine("Case {0}: {1}", count, s);
count++;
}
}
}
|
[["-", 0, 197, 0, 198, 0, 200, 0, 212, 0, 203], ["+", 0, 197, 0, 198, 0, 200, 0, 212, 0, 203]]
| 8
| 62
| 2
|
using System;
namespace aoj3a {
class Program {
static void Main(string[] args) {
for (int i = 1; i <= 10001; i++) {
string str = Console.ReadLine();
if (str == "0") {
break;
}
Console.WriteLine("Case " + i + ":" + str);
}
}
}
}
|
using System;
namespace aoj3a {
class Program {
static void Main(string[] args) {
for (int i = 1; i <= 10001; i++) {
string str = Console.ReadLine();
if (str == "0") {
break;
}
Console.WriteLine("Case " + i + ": " + str);
}
}
}
}
|
[["-", 0, 28, 0, 16, 31, 16, 12, 5, 0, 222], ["+", 0, 28, 0, 16, 31, 16, 12, 5, 0, 222]]
| 8
| 76
| 2
|
using System;
namespace Repetitive_Processing {
class Print_Test_Cases {
static void Main(string[] args) {
int c = 1;
while (true) {
var line = Console.ReadLine();
if (line == "0")
break;
Console.WriteLine("case " + c + ": " + line);
c++;
}
}
}
}
|
using System;
namespace Repetitive_Processing {
class Print_Test_Cases {
static void Main(string[] args) {
int c = 1;
while (true) {
var line = Console.ReadLine();
if (line == "0")
break;
Console.WriteLine("Case " + c + ": " + line);
c++;
}
}
}
}
|
[["-", 0, 16, 31, 16, 31, 16, 31, 5, 0, 222], ["+", 0, 16, 31, 16, 31, 16, 31, 5, 0, 222]]
| 8
| 72
| 2
|
using System;
class Program {
public static void Main(string[] args) {
int i = 0;
while (true) {
i++;
string read = Console.ReadLine();
int num = int.Parse(read);
if (num == 0)
break;
Console.WriteLine("Case {0}: {1]}", i, num);
}
}
}
|
using System;
class Program {
public static void Main(string[] args) {
int i = 0;
while (true) {
i++;
string read = Console.ReadLine();
int num = int.Parse(read);
if (num == 0)
break;
Console.WriteLine("Case {0}: {1}", i, num);
}
}
}
|
[["-", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222], ["+", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222]]
| 8
| 73
| 2
|
using System;
using System.Collections.Generic;
using System.Linq;
public class Program {
static void Main(string[] args) {
List<int> ValueList = new List<int>();
int readnum = Convert.ToInt32(Console.ReadLine());
while (readnum != 0) {
ValueList.Add(readnum);
readnum = Convert.ToInt32(Console.ReadLine());
}
for (int i = 0; i < ValueList.Count; i++) {
Console.WriteLine(string.Format("Case {0}: {1}"), i + 1, ValueList[i]);
}
}
}
|
using System;
using System.Collections.Generic;
using System.Linq;
public class Program {
static void Main(string[] args) {
List<int> ValueList = new List<int>();
int readnum = Convert.ToInt32(Console.ReadLine());
while (readnum != 0) {
ValueList.Add(readnum);
readnum = Convert.ToInt32(Console.ReadLine());
}
for (int i = 0; i < ValueList.Count; i++) {
Console.WriteLine(string.Format("Case {0}: {1}", i + 1, ValueList[i]));
}
}
}
|
[["-", 3, 4, 0, 28, 0, 213, 3, 4, 0, 25], ["+", 3, 4, 0, 28, 0, 213, 3, 4, 0, 25]]
| 8
| 128
| 2
|
using System;
namespace AizuOnlineJudge {
class Program {
static void Main(string[] args) {
for (int i = 0;; i++) {
var n = int.Parse(Console.ReadLine());
if (n == 0)
break;
Console.WriteLine("Case {0}: {1}", i, n);
}
}
}
}
|
using System;
namespace AizuOnlineJudge {
class Program {
static void Main(string[] args) {
for (int i = 1;; i++) {
var n = int.Parse(Console.ReadLine());
if (n == 0)
break;
Console.WriteLine("Case {0}: {1}", i, n);
}
}
}
}
|
[["-", 0, 7, 10, 198, 0, 200, 0, 212, 0, 203], ["+", 0, 7, 10, 198, 0, 200, 0, 212, 0, 203]]
| 8
| 70
| 2
|
using System;
class Program {
static void Main() {
int i = 0;
int n = 0;
while (true) {
n = int.Parse(Console.ReadLine());
if (n == 0)
break;
Console.WriteLine(string.Format("Case {0}: {1}"), ++i, n);
}
}
}
|
using System;
class Program {
static void Main() {
int i = 0;
int n = 0;
while (true) {
n = int.Parse(Console.ReadLine());
if (n == 0)
break;
Console.WriteLine(string.Format("Case {0}: {1}", ++i, n));
}
}
}
|
[["-", 3, 4, 0, 28, 0, 213, 3, 4, 0, 25], ["+", 3, 4, 0, 28, 0, 213, 3, 4, 0, 25]]
| 8
| 70
| 2
|
using System;
namespace ConsoleApp2 {
class Program {
static void Main(string[] args) {
for (int i = 1; i < 10001; i++) {
var n = int.Parse(Console.ReadLine());
if (n == 0) {
break;
}
Console.WriteLine("Case {1}: {2} ", i, n);
}
}
}
}
|
using System;
namespace ConsoleApp2 {
class Program {
static void Main(string[] args) {
for (int i = 1; i < 10001; i++) {
var x = int.Parse(Console.ReadLine());
if (x == 0) {
break;
} else
Console.WriteLine("Case {0}: {1}", i, x);
}
}
}
}
|
[["-", 8, 196, 0, 197, 0, 198, 0, 200, 141, 22], ["+", 8, 196, 0, 197, 0, 198, 0, 200, 141, 22], ["-", 0, 7, 8, 196, 0, 57, 15, 16, 31, 22], ["+", 0, 7, 8, 196, 0, 57, 15, 16, 31, 22], ["+", 8, 196, 0, 7, 8, 196, 0, 57, 0, 95], ["-", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222], ["+", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222], ["-", 0, 1, 0, 213, 3, 4, 0, 28, 0, 22], ["+", 75, 1, 0, 213, 3, 4, 0, 28, 0, 22]]
| 8
| 75
| 9
|
using System;
namespace AOJ {
public class Probrem {
public static void Main() {
string str;
for (var i = 0; (str = Console.ReadLine()) != "0"; i++)
Console.WriteLine("Case " + i + ": " + str);
}
}
}
|
using System;
namespace AOJ {
public class Probrem {
public static void Main() {
string str;
for (var i = 1; (str = Console.ReadLine()) != "0"; i++)
Console.WriteLine("Case " + i + ": " + str);
}
}
}
|
[["-", 0, 7, 10, 198, 0, 200, 0, 212, 0, 203], ["+", 0, 7, 10, 198, 0, 200, 0, 212, 0, 203]]
| 8
| 64
| 2
|
using System;
using System.Text;
namespace AOJ_Hello_World {
class Program {
static void Main(string[] args) {
int counter = 1;
while (true) {
long input = getInputs(1)[0];
if (input == 0)
break;
Console.WriteLine("Case {0} :{1}", counter++, input);
}
}
private static long[] getInputs(long length) {
var sab = Console.ReadLine();
long[] a = new long[length];
for (int i = 0; i < length; i++) {
a[i] = long.Parse(sab.Split(' ')[i]);
}
return a;
}
}
}
|
using System;
using System.Text;
namespace AOJ_Hello_World {
class Program {
static void Main(string[] args) {
int counter = 1;
while (true) {
long input = getInputs(1)[0];
if (input == 0)
break;
Console.WriteLine("Case {0}: {1}", counter++, input);
}
}
private static long[] getInputs(long length) {
var sab = Console.ReadLine();
long[] a = new long[length];
for (int i = 0; i < length; i++) {
a[i] = long.Parse(sab.Split(' ')[i]);
}
return a;
}
}
}
|
[["-", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222], ["+", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222]]
| 8
| 144
| 2
|
using System;
namespace ITP1_3_C {
class Program {
static void Main() {
while (true) {
string[] i = Console.ReadLine().Split(' ');
int x = int.Parse(i[0]);
int y = int.Parse(i[2]);
if (x == 0 && y == 0)
break;
Console.WriteLine("{0} {1}", Math.Min(x, y), Math.Max(x, y));
}
}
}
}
|
using System;
namespace ITP1_3_C {
class Program {
static void Main() {
while (true) {
string[] i = Console.ReadLine().Split(' ');
int x = int.Parse(i[0]);
int y = int.Parse(i[1]);
if (x == 0 && y == 0)
break;
Console.WriteLine("{0} {1}", Math.Min(x, y), Math.Max(x, y));
}
}
}
}
|
[["-", 0, 28, 0, 204, 206, 207, 0, 28, 0, 203], ["+", 0, 28, 0, 204, 206, 207, 0, 28, 0, 203]]
| 8
| 107
| 2
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Swapping_Two_Numbers {
class Program {
static void Main(string[] args) {
List<string> input = new List<string>();
while (true) {
string temp = "";
temp = Console.ReadLine();
if (temp.Equals("0 0")) {
break;
}
input.Add(temp);
}
foreach (string item in input) {
string[] temp = item.Split(' ');
int num1 = int.Parse(temp[0]);
int num2 = int.Parse(temp[1]);
if (num1 >= num2) {
Console.WriteLine(num1 + " " + num2);
} else {
Console.WriteLine(num2 + " " + num1);
}
}
}
}
}
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Swapping_Two_Numbers {
class Program {
static void Main(string[] args) {
List<string> input = new List<string>();
while (true) {
string temp = "";
temp = Console.ReadLine();
if (temp.Equals("0 0")) {
break;
}
input.Add(temp);
}
foreach (string item in input) {
string[] temp = item.Split(' ');
int num1 = int.Parse(temp[0]);
int num2 = int.Parse(temp[1]);
if (num1 <= num2) {
Console.WriteLine(num1 + " " + num2);
} else {
Console.WriteLine(num2 + " " + num1);
}
}
}
}
}
|
[["-", 0, 210, 8, 196, 0, 57, 15, 16, 17, 20], ["+", 0, 210, 8, 196, 0, 57, 15, 16, 17, 19]]
| 8
| 188
| 2
|
using System;
using System.Linq;
namespace ITP1_3_C_Swapping_Two_Numbers {
class Program {
static void Main(string[] args) {
string[] nums = null;
do {
if (nums != null)
Console.WriteLine(nums.Select(int.Parse)
.OrderBy(n => n)
.Select(n => n.ToString())
.Aggregate((acc, s) => acc + " " + s));
nums = Console.ReadLine().Split(' ');
} while (nums[0] != "0" && nums[1] != "0");
}
}
}
|
using System;
using System.Linq;
namespace ITP1_3_C_Swapping_Two_Numbers {
class Program {
static void Main(string[] args) {
string[] nums = null;
do {
if (nums != null)
Console.WriteLine(nums.Select(int.Parse)
.OrderBy(n => n)
.Select(n => n.ToString())
.Aggregate((acc, s) => acc + " " + s));
nums = Console.ReadLine().Split(' ');
} while (nums[0] != "0" || nums[1] != "0");
}
}
}
|
[["-", 0, 195, 8, 196, 0, 82, 15, 16, 17, 98], ["+", 0, 195, 8, 196, 0, 82, 15, 16, 17, 106]]
| 8
| 128
| 2
|
public partial class IntroductionToProgramming {
public static void Main() {
string[] str = System.Console.ReadLine().Split(' ');
decimal a = decimal.Parse(str[0]);
decimal b = decimal.Parse(str[1]);
while (a != 0M && b != 0M) {
System.Console.WriteLine((a < b ? a.ToString() : b.ToString()) + " " +
(a < b ? b.ToString() : a.ToString()));
string[] str2 = System.Console.ReadLine().Split(' ');
a = decimal.Parse(str2[0]);
b = decimal.Parse(str2[1]);
}
}
}
|
public partial class IntroductionToProgramming {
public static void Main() {
string[] str = System.Console.ReadLine().Split(' ');
decimal a = decimal.Parse(str[0]);
decimal b = decimal.Parse(str[1]);
while (!(a == 0M && b == 0M)) {
System.Console.WriteLine((a < b ? a.ToString() : b.ToString()) + " " +
(a < b ? b.ToString() : a.ToString()));
string[] str2 = System.Console.ReadLine().Split(' ');
a = decimal.Parse(str2[0]);
b = decimal.Parse(str2[1]);
}
}
}
|
[["+", 0, 195, 8, 196, 0, 52, 15, 241, 0, 111], ["+", 8, 196, 0, 52, 15, 241, 0, 23, 0, 24], ["-", 8, 196, 0, 52, 15, 16, 31, 16, 17, 79], ["+", 15, 241, 0, 23, 0, 16, 31, 16, 17, 60], ["-", 8, 196, 0, 52, 15, 16, 12, 16, 17, 79], ["+", 15, 241, 0, 23, 0, 16, 12, 16, 17, 60], ["+", 8, 196, 0, 52, 15, 241, 0, 23, 0, 25]]
| 8
| 163
| 7
|
using System;
using System.Collections.Generic;
using System.Text;
namespace ConsoleApplication2 {
class Program {
static void Main(string[] args) {
// string[] s =Console.ReadLine().Split(',');
// int w = int.Parse(s[0]);
// List<string> stringList1 = new List<string>();
// List<string> stringList2 = new List<string>();
for (int i = 0;; i++) {
string[] s = Console.ReadLine().Split(' ');
int a = int.Parse(s[0]);
int b = int.Parse(s[1]);
if ((a == 0) && (b == 0))
break;
if (a > b) {
Console.WriteLine(a + " " + b);
} else {
Console.WriteLine(b + " " + a);
}
}
// int n =int.Parse(s);
}
}
}
|
using System;
using System.Collections.Generic;
using System.Text;
namespace ConsoleApplication2 {
class Program {
static void Main(string[] args) {
// string[] s =Console.ReadLine().Split(',');
// int w = int.Parse(s[0]);
// List<string> stringList1 = new List<string>();
// List<string> stringList2 = new List<string>();
for (int i = 0;; i++) {
string[] s = Console.ReadLine().Split(' ');
int a = int.Parse(s[0]);
int b = int.Parse(s[1]);
if ((a == 0) && (b == 0))
break;
if (a < b) {
Console.WriteLine(a + " " + b);
} else {
Console.WriteLine(b + " " + a);
}
}
// int n =int.Parse(s);
}
}
}
|
[["-", 0, 7, 8, 196, 0, 57, 15, 16, 17, 47], ["+", 0, 7, 8, 196, 0, 57, 15, 16, 17, 18]]
| 8
| 149
| 2
|
using System;
using System.Collections.Generic;
using System.Text;
namespace ConsoleApplication7 {
class Program {
static void Main(string[] args) {
while (true) {
string[] s = Console.ReadLine().Split(' ');
int x = int.Parse(s[0]);
int y = int.Parse(s[1]);
if (x == 0 && y == 0) {
break;
}
if (x > y) {
Console.WriteLine(y + " " + x);
} else if (x < y) {
Console.WriteLine(x + " " + y);
}
}
}
}
}
|
using System;
using System.Collections.Generic;
using System.Text;
namespace ConsoleApplication7 {
class Program {
static void Main(string[] args) {
while (true) {
string[] s = Console.ReadLine().Split(' ');
int x = int.Parse(s[0]);
int y = int.Parse(s[1]);
if (x == 0 && y == 0) {
break;
}
if (x > y) {
Console.WriteLine(y + " " + x);
} else {
Console.WriteLine(x + " " + y);
}
}
}
}
}
|
[["-", 0, 52, 8, 196, 0, 57, 75, 57, 0, 121], ["-", 0, 52, 8, 196, 0, 57, 75, 57, 0, 24], ["-", 8, 196, 0, 57, 75, 57, 15, 16, 31, 22], ["-", 8, 196, 0, 57, 75, 57, 15, 16, 17, 18], ["-", 8, 196, 0, 57, 75, 57, 15, 16, 12, 22], ["-", 0, 52, 8, 196, 0, 57, 75, 57, 0, 25]]
| 8
| 141
| 6
|
using System;
using System.Collections.Generic;
using System.Text;
namespace ConsoleApplication9 {
class Program {
static void Main(string[] args) {
String[] str = Console.ReadLine().Split(' ');
int x = int.Parse(str[0]);
int y = int.Parse(str[1]);
while (x != 0 && y != 0) {
if (x > y) {
Console.WriteLine(y + " " + x);
} else if (x < y) {
Console.WriteLine(x + " " + y);
}
str = Console.ReadLine().Split(' ');
x = int.Parse(str[0]);
y = int.Parse(str[1]);
}
}
}
}
|
using System;
using System.Collections.Generic;
using System.Text;
namespace ConsoleApplication9 {
class Program {
static void Main(string[] args) {
String[] str = Console.ReadLine().Split(' ');
int x = int.Parse(str[0]);
int y = int.Parse(str[1]);
while (x != 0 || y != 0) {
if (x >= y) {
Console.WriteLine(y + " " + x);
} else if (x < y) {
Console.WriteLine(x + " " + y);
}
str = Console.ReadLine().Split(' ');
x = int.Parse(str[0]);
y = int.Parse(str[1]);
}
}
}
}
|
[["-", 0, 195, 8, 196, 0, 52, 15, 16, 17, 98], ["+", 0, 195, 8, 196, 0, 52, 15, 16, 17, 106], ["-", 0, 52, 8, 196, 0, 57, 15, 16, 17, 47], ["+", 0, 52, 8, 196, 0, 57, 15, 16, 17, 20]]
| 8
| 172
| 4
|
using System;
class Swapping_Two_Numbers {
public static void Main() {
while (true) {
string number_str = Console.ReadLine();
string[] tmp_number = number_str.Split(' ');
int a = int.Parse(tmp_number[0]);
int b = int.Parse(tmp_number[1]);
if (a == 0 && b == 0)
break;
if (a < b) {
int tmp = a;
a = b;
b = tmp;
}
Console.WriteLine("{0} {1}", a, b);
}
}
}
|
using System;
class Swapping_Two_Numbers {
public static void Main() {
while (true) {
string number_str = Console.ReadLine();
string[] tmp_number = number_str.Split(' ');
int a = int.Parse(tmp_number[0]);
int b = int.Parse(tmp_number[1]);
if (a == 0 && b == 0)
break;
if (a > b) {
int tmp = a;
a = b;
b = tmp;
}
Console.WriteLine("{0} {1}", a, b);
}
}
}
|
[["-", 0, 52, 8, 196, 0, 57, 15, 16, 17, 18], ["+", 0, 52, 8, 196, 0, 57, 15, 16, 17, 47]]
| 8
| 116
| 2
|
using System;
namespace tes {
class Program {
static void Main(string[] args) {
int a = 0, i = 0;
int[] x = new int[100000];
int[] y = new int[100000];
while (a < 20) {
var line1 = Console.ReadLine().Split();
x[i] = int.Parse(line1[0]);
y[i] = int.Parse(line1[1]);
if ((x[i] == 0) && (y[i] == 0)) {
break;
}
i++;
}
for (int z = 0; z < i; z++) {
if (x[z] > y[z]) {
Console.WriteLine(x[z] + " " + y[z]);
} else if (x[z] < y[z]) {
Console.WriteLine(y[z] + " " + x[z]);
} else {
Console.WriteLine(x[z] + " " + y[z]);
}
}
}
}
}
|
using System;
namespace tes {
class Program {
static void Main(string[] args) {
int a = 0, i = 0;
int[] x = new int[100000];
int[] y = new int[100000];
while (a < 20) {
var line1 = Console.ReadLine().Split();
x[i] = int.Parse(line1[0]);
y[i] = int.Parse(line1[1]);
if ((x[i] == 0) && (y[i] == 0)) {
break;
}
i++;
}
for (int z = 0; z < i; z++) {
if (x[z] < y[z]) {
Console.WriteLine(x[z] + " " + y[z]);
} else if (x[z] > y[z]) {
Console.WriteLine(y[z] + " " + x[z]);
} else {
Console.WriteLine(x[z] + " " + y[z]);
}
}
}
}
}
|
[["-", 0, 7, 8, 196, 0, 57, 15, 16, 17, 47], ["+", 0, 7, 8, 196, 0, 57, 15, 16, 17, 18], ["-", 8, 196, 0, 57, 75, 57, 15, 16, 17, 18], ["+", 8, 196, 0, 57, 75, 57, 15, 16, 17, 47]]
| 8
| 236
| 4
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace ConsoleApp9 {
class Program {
public static void Main(string[] args) {
while (true) {
string[] sss = Console.ReadLine().Split(' ');
int a = int.Parse(sss[0]);
int b = int.Parse(sss[1]);
if (a == 0 && b == 0) {
break;
} else if (a > b)
Console.WriteLine("{0} {1}", a, b);
else
Console.WriteLine("{0} {1}", b, a);
}
}
}
}
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace ConsoleApp9 {
class Program {
public static void Main(string[] args) {
while (true) {
string[] sss = Console.ReadLine().Split(' ');
int a = int.Parse(sss[0]);
int b = int.Parse(sss[1]);
if (a == 0 && b == 0) {
break;
} else if (a < b)
Console.WriteLine("{0} {1}", a, b);
else
Console.WriteLine("{0} {1}", b, a);
}
}
}
}
|
[["-", 8, 196, 0, 57, 75, 57, 15, 16, 17, 47], ["+", 8, 196, 0, 57, 75, 57, 15, 16, 17, 18]]
| 8
| 138
| 2
|
using System;
namespace AOJ {
class Program {
static void Main(string[] args) {
while (true) {
var read = Console.ReadLine();
var temp_string = read.Split(' ');
int a = int.Parse(temp_string[0]), b = int.Parse(temp_string[1]);
if (a == 0 && b == 0) {
break;
}
if (a < b) {
int temp = a;
a = b;
b = temp;
}
Console.WriteLine(a + " " + b);
}
}
}
}
|
using System;
namespace AOJ {
class Program {
static void Main(string[] args) {
while (true) {
var read = Console.ReadLine();
var temp_string = read.Split(' ');
int a = int.Parse(temp_string[0]), b = int.Parse(temp_string[1]);
if (a == 0 && b == 0) {
break;
}
if (a > b) {
int temp = a;
a = b;
b = temp;
}
Console.WriteLine(a + " " + b);
}
}
}
}
|
[["-", 0, 52, 8, 196, 0, 57, 15, 16, 17, 18], ["+", 0, 52, 8, 196, 0, 57, 15, 16, 17, 47]]
| 8
| 122
| 2
|
using System;
using System.Collections.Generic;
class ITP1 {
static void Main(string[] args) {
// var exStdIn = new System.IO.StreamReader("stdin.txt");
// System.Console.SetIn(exStdIn);
Q3_C();
// int[] a = Array.ConvertAll(Console.ReadLine().Split(' '), new
// Converter<String, int>(s => int.Parse(s)));
}
static void Q1() {
int input = int.Parse(Console.ReadLine());
int h = input / 3600;
int m = input % 3600 / 60;
int s = input % 3600 % 60;
Console.WriteLine(String.Format("{0}:{1}:{2}", h, m, s));
}
static void Q2_A() {
int[] a = Array.ConvertAll(Console.ReadLine().Split(' '),
new Converter<String, int>(s => int.Parse(s)));
String sign = a[0] - a[1] > 0 ? ">" : a[0] - a[1] == 0 ? "==" : "<";
Console.WriteLine(String.Format("a {0} b", sign));
}
static void Q2_B() {
int[] a = Array.ConvertAll(Console.ReadLine().Split(' '),
new Converter<String, int>(s => int.Parse(s)));
String answer = a[2] - a[1] > 0 ? a[1] - a[0] > 0 ? "Yes" : "No" : "No";
Console.WriteLine(answer);
}
static void Q2_C() {
List<int> a = new List<int>(
Array.ConvertAll(Console.ReadLine().Split(' '),
new Converter<String, int>(s => int.Parse(s))));
a.Sort();
Console.WriteLine(String.Format("{0} {1} {2}", a[0], a[1], a[2]));
}
static void Q2_D() {
int[] a = Array.ConvertAll(Console.ReadLine().Split(' '),
new Converter<String, int>(s => int.Parse(s)));
int chk = 0;
// x-max
if (a[0] - a[2] - a[4] >= 0)
chk++;
// x-min
if (a[2] - a[4] >= 0)
chk++;
// y-max
if (a[1] - a[3] - a[4] >= 0)
chk++;
// y-min
if (a[3] - a[4] >= 0)
chk++;
String answer = chk == 4 ? "Yes" : "No";
Console.WriteLine(answer);
}
static void Q3_A() {
for (int i = 0; i < 1000; i++) {
Console.WriteLine("Hello World");
}
}
static void Q3_B() {
String a = "";
for (int i = 1; i <= 10000; i++) {
a = Console.ReadLine();
if (a != null) {
Console.WriteLine("Case {0}: {1}", i, a);
} else {
break;
}
}
}
static void Q3_C() {
while (true) {
String str = Console.ReadLine();
if (str == null)
break;
int[] a = Array.ConvertAll(str.Split(' '),
new Converter<String, int>(s => int.Parse(s)));
List<int> tempList = new List<int>(a);
tempList.Sort();
Console.WriteLine(String.Format("{0} {1}", tempList[0], tempList[1]));
}
}
}
|
using System;
using System.Collections.Generic;
class ITP1 {
static void Main(string[] args) {
// var exStdIn = new System.IO.StreamReader("stdin.txt");
// System.Console.SetIn(exStdIn);
Q3_C();
// int[] a = Array.ConvertAll(Console.ReadLine().Split(' '), new
// Converter<String, int>(s => int.Parse(s)));
}
static void Q1() {
int input = int.Parse(Console.ReadLine());
int h = input / 3600;
int m = input % 3600 / 60;
int s = input % 3600 % 60;
Console.WriteLine(String.Format("{0}:{1}:{2}", h, m, s));
}
static void Q2_A() {
int[] a = Array.ConvertAll(Console.ReadLine().Split(' '),
new Converter<String, int>(s => int.Parse(s)));
String sign = a[0] - a[1] > 0 ? ">" : a[0] - a[1] == 0 ? "==" : "<";
Console.WriteLine(String.Format("a {0} b", sign));
}
static void Q2_B() {
int[] a = Array.ConvertAll(Console.ReadLine().Split(' '),
new Converter<String, int>(s => int.Parse(s)));
String answer = a[2] - a[1] > 0 ? a[1] - a[0] > 0 ? "Yes" : "No" : "No";
Console.WriteLine(answer);
}
static void Q2_C() {
List<int> a = new List<int>(
Array.ConvertAll(Console.ReadLine().Split(' '),
new Converter<String, int>(s => int.Parse(s))));
a.Sort();
Console.WriteLine(String.Format("{0} {1} {2}", a[0], a[1], a[2]));
}
static void Q2_D() {
int[] a = Array.ConvertAll(Console.ReadLine().Split(' '),
new Converter<String, int>(s => int.Parse(s)));
int chk = 0;
// x-max
if (a[0] - a[2] - a[4] >= 0)
chk++;
// x-min
if (a[2] - a[4] >= 0)
chk++;
// y-max
if (a[1] - a[3] - a[4] >= 0)
chk++;
// y-min
if (a[3] - a[4] >= 0)
chk++;
String answer = chk == 4 ? "Yes" : "No";
Console.WriteLine(answer);
}
static void Q3_A() {
for (int i = 0; i < 1000; i++) {
Console.WriteLine("Hello World");
}
}
static void Q3_B() {
String a = "";
for (int i = 1; i <= 10000; i++) {
a = Console.ReadLine();
if (a != null) {
Console.WriteLine("Case {0}: {1}", i, a);
} else {
break;
}
}
}
static void Q3_C() {
while (true) {
String str = Console.ReadLine();
if (str == null || str == "0 0")
break;
int[] a = Array.ConvertAll(str.Split(' '),
new Converter<String, int>(s => int.Parse(s)));
List<int> tempList = new List<int>(a);
tempList.Sort();
Console.WriteLine(String.Format("{0} {1}", tempList[0], tempList[1]));
}
}
}
|
[["+", 0, 52, 8, 196, 0, 57, 15, 16, 17, 106], ["+", 8, 196, 0, 57, 15, 16, 12, 16, 31, 22], ["+", 8, 196, 0, 57, 15, 16, 12, 16, 17, 60], ["+", 0, 57, 15, 16, 12, 16, 12, 5, 0, 62], ["+", 0, 57, 15, 16, 12, 16, 12, 5, 0, 222]]
| 8
| 751
| 6
|
using System;
using System.Linq;
namespace _3_C {
class Program {
static void Main(string[] args) {
bool z = true;
while (z) {
int[] x = Console.ReadLine().Split().Select(int.Parse).ToArray();
if (x[0] == 0 && x[1] == 0) {
z = false;
}
Array.Sort(x);
Console.WriteLine(x[0] + " " + x[1]);
}
}
}
}
|
using System;
using System.Linq;
namespace _3_C {
class Program {
static void Main(string[] args) {
bool z = true;
while (z) {
int[] x = Console.ReadLine().Split().Select(int.Parse).ToArray();
if (x[0] == 0 && x[1] == 0) {
z = false;
} else {
Array.Sort(x);
Console.WriteLine(x[0] + " " + x[1]);
}
}
}
}
}
|
[["+", 8, 196, 0, 52, 8, 196, 0, 57, 0, 95], ["+", 0, 52, 8, 196, 0, 57, 75, 196, 0, 45], ["+", 0, 52, 8, 196, 0, 57, 75, 196, 0, 46]]
| 8
| 112
| 3
|
using System;
public class Program {
public static void Main(string[] args) {
var ss = new StreamScanner();
//---------------------------------
// var x = ss.Next<int>();
// var y = ss.Next<int>();
for (int i = 1; i <= 3000; i++) {
int x = ss.Next<int>();
int y = ss.Next<int>();
if (x == 0 || y == 0) {
break;
} else if (x <= y) {
Console.WriteLine(x + " " + y);
} else if (x > y) {
Console.WriteLine(y + " " + x);
}
}
/*
//????????????int, double, string?????????????????£????????????
int i = ss.Next<int>();
double d = ss.Next<double>();
string s = ss.Next<string>();
//?????°???????????????????????¨?????????????????????????????????????????????????´???????
int[] array = ss.Next<int>(10);
*/
//---------------------------------
}
}
public class StreamScanner {
private readonly char[] _c = { ' ' };
private int _index = -1;
private string[] _input = new string[0];
private readonly System.IO.StreamReader _sr =
new System.IO.StreamReader(Console.OpenStandardInput());
public T Next<T>() {
if (_index == _input.Length - 1) {
_index = -1;
while (true) {
string rl = _sr.ReadLine();
if (rl == null) {
if (typeof(T).IsClass)
return default(T);
return (T) typeof(T).GetField("MinValue").GetValue(null);
}
if (rl != "") {
_input = rl.Split(_c, StringSplitOptions.RemoveEmptyEntries);
break;
}
}
}
return (T)Convert.ChangeType(
_input[++_index], typeof(T),
System.Globalization.CultureInfo.InvariantCulture);
}
public T[] Next<T>(int x) {
var ret = new T[x];
for (var i = 0; i < x; ++i)
ret[i] = Next<T>();
return ret;
}
public T[][] Next<T>(int x, int y) {
var ret = new T[y][];
for (var i = 0; i < y; ++i)
ret[i] = Next<T>(x);
return ret;
}
}
|
using System;
public class Program {
public static void Main(string[] args) {
var ss = new StreamScanner();
//---------------------------------
// var x = ss.Next<int>();
// var y = ss.Next<int>();
for (int i = 1; i <= 3000; i++) {
int x = ss.Next<int>();
int y = ss.Next<int>();
if (x == 0 && y == 0) {
break;
} else if (x <= y) {
Console.WriteLine(x + " " + y);
} else if (x > y) {
Console.WriteLine(y + " " + x);
}
}
/*
//????????????int, double, string?????????????????£????????????
int i = ss.Next<int>();
double d = ss.Next<double>();
string s = ss.Next<string>();
//?????°???????????????????????¨?????????????????????????????????????????????????´???????
int[] array = ss.Next<int>(10);
*/
//---------------------------------
}
}
public class StreamScanner {
private readonly char[] _c = { ' ' };
private int _index = -1;
private string[] _input = new string[0];
private readonly System.IO.StreamReader _sr =
new System.IO.StreamReader(Console.OpenStandardInput());
public T Next<T>() {
if (_index == _input.Length - 1) {
_index = -1;
while (true) {
string rl = _sr.ReadLine();
if (rl == null) {
if (typeof(T).IsClass)
return default(T);
return (T) typeof(T).GetField("MinValue").GetValue(null);
}
if (rl != "") {
_input = rl.Split(_c, StringSplitOptions.RemoveEmptyEntries);
break;
}
}
}
return (T)Convert.ChangeType(
_input[++_index], typeof(T),
System.Globalization.CultureInfo.InvariantCulture);
}
public T[] Next<T>(int x) {
var ret = new T[x];
for (var i = 0; i < x; ++i)
ret[i] = Next<T>();
return ret;
}
public T[][] Next<T>(int x, int y) {
var ret = new T[y][];
for (var i = 0; i < y; ++i)
ret[i] = Next<T>(x);
return ret;
}
}
|
[["-", 0, 7, 8, 196, 0, 57, 15, 16, 17, 106], ["+", 0, 7, 8, 196, 0, 57, 15, 16, 17, 98]]
| 8
| 441
| 2
|
using System;
using System.Collections.Generic;
using System.Linq;
public class Program {
static void Main(string[] args) {
List<int> Left = new List<int>();
List<int> Right = new List<int>();
for (;;) {
var ReadValue = Console.ReadLine().Split(' ');
if (ReadValue[0] == "0" && ReadValue[1] == "0")
break;
Left.Add(Convert.ToInt32(ReadValue[0]));
Right.Add(Convert.ToInt32(ReadValue[1]));
}
for (int i = 0; i < Left.Count; i++) {
if (Left[i] < Right[i])
Console.WriteLine(string.Format("{0} {1}"), Left[i], Right[i]);
else
Console.WriteLine(string.Format("{0} {1}"), Right[i], Left[i]);
}
}
}
|
using System;
using System.Collections.Generic;
using System.Linq;
public class Program {
static void Main(string[] args) {
List<int> Left = new List<int>();
List<int> Right = new List<int>();
for (;;) {
var ReadValue = Console.ReadLine().Split(' ');
if (ReadValue[0] == "0" && ReadValue[1] == "0")
break;
Left.Add(Convert.ToInt32(ReadValue[0]));
Right.Add(Convert.ToInt32(ReadValue[1]));
}
for (int i = 0; i < Left.Count; i++) {
if (Left[i] < Right[i])
Console.WriteLine(string.Format("{0} {1}", Left[i], Right[i]));
else
Console.WriteLine(string.Format("{0} {1}", Right[i], Left[i]));
}
}
}
|
[["-", 3, 4, 0, 28, 0, 213, 3, 4, 0, 25], ["+", 3, 4, 0, 28, 0, 213, 3, 4, 0, 25]]
| 8
| 213
| 4
|
using System;
using System.Linq;
namespace AizuOnlineJudge {
class Program {
static void Main(string[] args) {
for (int i = 0;; i++) {
var n = Array.ConvertAll(Console.ReadLine().Split(' '), int.Parse)
.OrderBy(s => s)
.ToArray();
if (n[0] == 0 || n[1] == 0)
break;
Console.WriteLine(n[0] + " " + n[1]);
}
}
}
}
|
using System;
using System.Linq;
namespace AizuOnlineJudge {
class Program {
static void Main(string[] args) {
for (int i = 0;; i++) {
var n = Array.ConvertAll(Console.ReadLine().Split(' '), int.Parse)
.OrderBy(s => s)
.ToArray();
if (n[0] == 0 & n[1] == 0)
break;
Console.WriteLine(n[0] + " " + n[1]);
}
}
}
}
|
[["-", 0, 7, 8, 196, 0, 57, 15, 16, 17, 106], ["+", 0, 7, 8, 196, 0, 57, 15, 16, 17, 67]]
| 8
| 113
| 2
|
using System;
class Program {
static void Main() {
int a, b;
string[] arys;
string result;
//入力情報取得
arys = Console.ReadLine().Split(' ');
a = int.Parse(arys[0]);
b = int.Parse(arys[1]);
//両方 0 の場合は処理を抜ける
while (a != 0 || b != 0) {
result = "";
if (a > b) {
//左が大きい場合は結果を入替える
result = string.Format("{0} {1}", b, a);
} else {
result = string.Format("{0} {1}", a, b);
}
//結果表示
Console.Write(result);
//次の入力情報を取得
arys = Console.ReadLine().Split(' ');
a = int.Parse(arys[0]);
b = int.Parse(arys[1]);
}
}
}
|
using System;
class Program {
static void Main() {
int a, b;
string[] arys;
string result;
//入力情報取得
arys = Console.ReadLine().Split(' ');
a = int.Parse(arys[0]);
b = int.Parse(arys[1]);
//両方 0 の場合は処理を抜ける
while (a != 0 || b != 0) {
result = "";
if (a > b) {
//左が大きい場合は結果を入替える
result = string.Format("{0} {1}", b, a);
} else {
result = string.Format("{0} {1}", a, b);
}
//結果表示
Console.WriteLine(result);
//次の入力情報を取得
arys = Console.ReadLine().Split(' ');
a = int.Parse(arys[0]);
b = int.Parse(arys[1]);
}
}
}
|
[["-", 8, 196, 0, 1, 0, 213, 63, 214, 141, 22], ["+", 8, 196, 0, 1, 0, 213, 63, 214, 141, 22]]
| 8
| 175
| 2
|
using System;
class Program {
static void Main(string[] args) {
int x, y, z;
while (true) {
string[] num = Console.ReadLine().Split(' ');
x = int.Parse(num[0]);
y = int.Parse(num[1]);
if (x > y) {
z = x;
x = y;
y = z;
if (x == 0 && y == 0) {
break;
}
Console.WriteLine(x + " " + y);
}
}
}
}
|
using System;
class Program {
static void Main(string[] args) {
int x, y, z;
while (true) {
string[] num = Console.ReadLine().Split(' ');
x = int.Parse(num[0]);
y = int.Parse(num[1]);
if (x > y) {
z = x;
x = y;
y = z;
}
if (x == 0 && y == 0) {
break;
}
Console.WriteLine(x + " " + y);
}
}
}
|
[["+", 0, 52, 8, 196, 0, 57, 64, 196, 0, 46], ["-", 0, 52, 8, 196, 0, 57, 64, 196, 0, 46]]
| 8
| 120
| 2
|
using System;
namespace ConsoleApp2 {
class Program {
static void Main(string[] args) {
int x = 0, y = 0;
while (true) {
string[] str = Console.ReadLine().Split(' ');
x = int.Parse(str[0]);
y = int.Parse(str[1]);
if (x == 0 && y == 0) {
break;
}
if (x < y)
Console.Write("{0} {1}", x, y);
else
Console.WriteLine("{0} {1}", y, x);
}
}
}
}
|
using System;
namespace ConsoleApp2 {
class Program {
static void Main(string[] args) {
int x = 0, y = 0;
while (true) {
string[] str = Console.ReadLine().Split(' ');
x = int.Parse(str[0]);
y = int.Parse(str[1]);
if (x == 0 && y == 0) {
break;
}
if (x < y)
Console.WriteLine("{0} {1}", x, y);
else
Console.WriteLine("{0} {1}", y, x);
}
}
}
}
|
[["-", 0, 57, 64, 1, 0, 213, 63, 214, 141, 22], ["+", 0, 57, 64, 1, 0, 213, 63, 214, 141, 22]]
| 8
| 126
| 2
|
using System;
class swapping {
public static void Main() {
for (int i = 0; i < 3000; i++) {
String[] s = Console.ReadLine().Split();
int x = int.Parse(s[0]);
int y = int.Parse(s[1]);
if (x < y) {
Console.WriteLine("{0} {1}", x, y);
} else if (x > y) {
Console.WriteLine("{0} {1}", y, x);
} else if (x == 0 && y == 0) {
break;
} else if (x == 0 && y == 0) {
Console.WriteLine("{0} {1}", x, y);
}
}
}
}
|
using System;
class swapping {
public static void Main() {
for (int i = 0; i < 3000; i++) {
String[] s = Console.ReadLine().Split();
int x = int.Parse(s[0]);
int y = int.Parse(s[1]);
if (x < y) {
Console.WriteLine("{0} {1}", x, y);
} else if (x > y) {
Console.WriteLine("{0} {1}", y, x);
} else if (x == 0 && y == 0) {
break;
} else if (x == y) {
Console.WriteLine("{0} {1}", x, y);
}
}
}
}
|
[["-", 75, 57, 75, 57, 15, 16, 31, 16, 12, 203], ["-", 75, 57, 75, 57, 75, 57, 15, 16, 17, 98], ["-", 75, 57, 75, 57, 15, 16, 12, 16, 17, 60], ["-", 75, 57, 75, 57, 15, 16, 12, 16, 12, 203]]
| 8
| 156
| 4
|
using System;
class Program {
static void Main() {
while (true) {
string[] input = Console.ReadLine().Split(' ');
int x = int.Parse(input[0]);
int y = int.Parse(input[1]);
if (x < y) {
int tmp = x;
x = y;
y = tmp;
}
if (x == 0 && y == 0)
break;
Console.WriteLine("{0} {1}", x, y);
}
}
}
|
using System;
class Program {
static void Main() {
while (true) {
string[] input = Console.ReadLine().Split(' ');
int x = int.Parse(input[0]);
int y = int.Parse(input[1]);
if (x > y) {
int tmp = x;
x = y;
y = tmp;
}
if (x == 0 && y == 0)
break;
Console.WriteLine("{0} {1}", x, y);
}
}
}
|
[["-", 0, 52, 8, 196, 0, 57, 15, 16, 17, 18], ["+", 0, 52, 8, 196, 0, 57, 15, 16, 17, 47]]
| 8
| 110
| 2
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace aoj1 {
class Program {
static void Main() {
int[] num;
for (;;) {
num = IntInput();
Array.Sort(num);
if (num[0] != 0 && num[1] != 0) {
Console.WriteLine("{0} {1}", num[0], num[1]);
} else {
break;
}
}
}
static int[] IntInput() {
string[] strs = Console.ReadLine().Split(' ');
int[] numbers = new int[strs.Length];
for (int i = 0; i < strs.Length; i++) {
numbers[i] = int.Parse(strs[i]);
}
return numbers;
}
}
}
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace aoj1 {
class Program {
static void Main() {
int[] num;
for (;;) {
num = IntInput();
Array.Sort(num);
if (num[0] != 0 || num[1] != 0) {
Console.WriteLine("{0} {1}", num[0], num[1]);
} else {
break;
}
}
}
static int[] IntInput() {
string[] strs = Console.ReadLine().Split(' ');
int[] numbers = new int[strs.Length];
for (int i = 0; i < strs.Length; i++) {
numbers[i] = int.Parse(strs[i]);
}
return numbers;
}
}
}
|
[["-", 0, 7, 8, 196, 0, 57, 15, 16, 17, 98], ["+", 0, 7, 8, 196, 0, 57, 15, 16, 17, 106]]
| 8
| 178
| 2
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace manyDiv {
class Program {
static void Main(string[] args) {
int a, b, c, count = 0;
String[] str = Console.ReadLine().Split(' ');
a = int.Parse(str[0]);
b = int.Parse(str[1]);
c = int.Parse(str[2]);
for (int i = a; i < b; i++) {
if (c % i == 0)
count++;
}
Console.WriteLine(count);
}
}
}
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace manyDiv {
class Program {
static void Main(string[] args) {
int a, b, c, count = 0;
String[] str = Console.ReadLine().Split(' ');
a = int.Parse(str[0]);
b = int.Parse(str[1]);
c = int.Parse(str[2]);
for (int i = a; i <= b; i++) {
if (c % i == 0)
count++;
}
Console.WriteLine(count);
}
}
}
|
[["-", 0, 195, 8, 196, 0, 7, 15, 16, 17, 18], ["+", 0, 195, 8, 196, 0, 7, 15, 16, 17, 19]]
| 8
| 138
| 2
|
using System;
namespace HowManyDivisors {
class MainClass {
public static void Main(string[] args) {
int cnt = 0;
string input = Console.ReadLine();
char[] CharSeparators = new char[] { ' ' };
string[] array = input.Split(CharSeparators);
string array1 = array[0];
string array2 = array[1];
string array3 = array[2];
int a = int.Parse(array1);
int b = int.Parse(array2);
int c = int.Parse(array3);
for (int i = a; i <= b; i++) {
if ((c % i) == 0) {
cnt++;
}
Console.WriteLine(cnt);
}
}
}
}
|
using System;
namespace HowManyDivisors {
class MainClass {
public static void Main(string[] args) {
int cnt = 0;
string input = Console.ReadLine();
char[] CharSeparators = new char[] { ' ' };
string[] array = input.Split(CharSeparators);
string array1 = array[0];
string array2 = array[1];
string array3 = array[2];
int a = int.Parse(array1);
int b = int.Parse(array2);
int c = int.Parse(array3);
for (int i = a; i <= b; i++) {
if ((c % i) == 0) {
cnt++;
}
}
Console.WriteLine(cnt);
}
}
}
|
[["+", 0, 195, 8, 196, 0, 7, 8, 196, 0, 46], ["-", 0, 195, 8, 196, 0, 7, 8, 196, 0, 46]]
| 8
| 156
| 2
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace ConsoleApplication1 {
class Program {
static void Main(string[] args) {
String[] Array = Console.ReadLine().Split(' ');
int a = int.Parse(Array[0]);
int b = int.Parse(Array[1]);
int c = int.Parse(Array[2]);
int count = 0;
for (int i = a; i < b; ++i) {
if (c % i == 0) {
++count;
}
}
Console.WriteLine(count);
}
}
}
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace ConsoleApplication1 {
class Program {
static void Main(string[] args) {
String[] Array = Console.ReadLine().Split(' ');
int a = int.Parse(Array[0]);
int b = int.Parse(Array[1]);
int c = int.Parse(Array[2]);
int count = 0;
for (int i = a; i <= b; ++i) {
if (c % i == 0) {
++count;
}
}
Console.WriteLine(count);
}
}
}
|
[["-", 0, 195, 8, 196, 0, 7, 15, 16, 17, 18], ["+", 0, 195, 8, 196, 0, 7, 15, 16, 17, 19]]
| 8
| 137
| 2
|
using System;
using System.Collections.Generic;
using System.Text;
namespace ConsoleApplication2 {
class Program {
static void Main(string[] args) {
string[] s = Console.ReadLine().Split(' ');
int a = int.Parse(s[0]);
int b = int.Parse(s[1]);
int c = int.Parse(s[2]);
int count = 0;
for (int i = a; i <= b; i++) {
if ((c / i) == 0) {
count++;
}
}
Console.WriteLine(count);
}
}
}
|
using System;
using System.Collections.Generic;
using System.Text;
namespace ConsoleApplication2 {
class Program {
static void Main(string[] args) {
string[] s = Console.ReadLine().Split(' ');
int a = int.Parse(s[0]);
int b = int.Parse(s[1]);
int c = int.Parse(s[2]);
int count = 0;
for (int i = a; i <= b; i++) {
if ((c % i) == 0) {
count++;
}
}
Console.WriteLine(count);
}
}
}
|
[["-", 0, 57, 15, 16, 31, 23, 0, 16, 17, 85], ["+", 0, 57, 15, 16, 31, 23, 0, 16, 17, 109]]
| 8
| 134
| 2
|
using System;
namespace ConsoleApplication1 {
class Program {
static void Main(string[] args) {
string[] s = Console.ReadLine().Split(' ');
int a = int.Parse(s[0]);
int b = int.Parse(s[1]);
int c = int.Parse(s[2]);
int d = 0;
for (int i = a; i <= b; i++) {
if (c % i == 0) {
d++;
}
}
Console.WriteLine("d");
}
}
}
|
using System;
namespace ConsoleApplication1 {
class Program {
static void Main(string[] args) {
string[] s = Console.ReadLine().Split(' ');
int a = int.Parse(s[0]);
int b = int.Parse(s[1]);
int c = int.Parse(s[2]);
int d = 0;
for (int i = a; i <= b; i++) {
if (c % i == 0) {
d++;
}
}
Console.WriteLine(d);
}
}
}
|
[["-", 0, 213, 3, 4, 0, 28, 0, 5, 0, 62]]
| 8
| 122
| 2
|
using System;
using System.Collections.Generic;
using System.Text;
namespace ConsoleApplication9 {
class Program {
static void Main(string[] args) {
String[] str = Console.ReadLine().Split(' ');
int H = int.Parse(str[0]);
int W = int.Parse(str[1]);
while (H != 0 || W != 0) {
for (int i = 0; i < H; i++) {
for (int j = 0; j < W; j++) {
Console.Write("#");
}
Console.WriteLine();
}
str = Console.ReadLine().Split(' ');
H = int.Parse(str[0]);
W = int.Parse(str[1]);
}
}
}
}
|
using System;
using System.Collections.Generic;
using System.Text;
namespace ConsoleApplication9 {
class Program {
static void Main(string[] args) {
String[] str = Console.ReadLine().Split(' ');
int H = int.Parse(str[0]);
int W = int.Parse(str[1]);
while (H != 0 || W != 0) {
for (int i = 0; i < H; i++) {
for (int j = 0; j < W; j++) {
Console.Write("#");
}
Console.WriteLine();
}
Console.WriteLine();
str = Console.ReadLine().Split(' ');
H = int.Parse(str[0]);
W = int.Parse(str[1]);
}
}
}
}
|
[["+", 8, 196, 0, 1, 0, 213, 63, 214, 205, 22], ["+", 8, 196, 0, 1, 0, 213, 63, 214, 0, 131], ["+", 8, 196, 0, 1, 0, 213, 63, 214, 141, 22], ["+", 8, 196, 0, 1, 0, 213, 3, 4, 0, 24], ["+", 8, 196, 0, 1, 0, 213, 3, 4, 0, 25], ["+", 8, 196, 0, 52, 8, 196, 0, 1, 0, 35]]
| 8
| 176
| 6
|
using System;
namespace ConsoleApplication36 {
class Program {
static void Main(string[] args) {
while (true) {
string s = Console.ReadLine();
string[] ss = s.Split(' ');
int H = int.Parse(ss[0]);
int W = int.Parse(ss[1]);
int j;
int x;
if (H == 0 && W == 0) {
break;
} else {
for (x = 0; x < W; x++) {
for (j = 0; j < H; j++) {
Console.Write("#");
}
Console.WriteLine(" ");
}
Console.WriteLine("");
}
}
}
}
}
|
using System;
namespace ConsoleApplication36 {
class Program {
static void Main(string[] args) {
while (true) {
string s = Console.ReadLine();
string[] ss = s.Split(' ');
int H = int.Parse(ss[0]);
int W = int.Parse(ss[1]);
int j;
int x;
if (H == 0 && W == 0) {
break;
} else {
for (x = 0; x < H; x++) {
for (j = 0; j < W; j++) {
Console.Write("#");
}
Console.WriteLine("");
}
Console.WriteLine("");
}
}
}
}
}
|
[["-", 0, 57, 75, 196, 0, 7, 15, 16, 12, 22], ["+", 0, 57, 75, 196, 0, 7, 15, 16, 12, 22], ["-", 0, 7, 8, 196, 0, 7, 15, 16, 12, 22], ["+", 0, 7, 8, 196, 0, 7, 15, 16, 12, 22], ["-", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222]]
| 8
| 156
| 5
|
using System;
using System.Linq;
class MainClass {
public static void Main() {
for (;;) {
string[] str = Console.ReadLine().Split(' ');
int h = int.Parse(str[0]), w = int.Parse(str[1]);
if (h == 0 && w == 0)
break;
for (int i = 0; i < h; i++) {
for (int j = 0; j < w; j++) {
Console.Write('#');
}
Console.WriteLine();
}
}
}
}
|
using System;
using System.Linq;
class MainClass {
public static void Main() {
for (;;) {
string[] str = Console.ReadLine().Split(' ');
int h = int.Parse(str[0]), w = int.Parse(str[1]);
if (h == 0 && w == 0)
break;
for (int i = 0; i < h; i++) {
for (int j = 0; j < w; j++) {
Console.Write('#');
}
Console.WriteLine();
}
Console.WriteLine();
}
}
}
|
[["+", 8, 196, 0, 1, 0, 213, 63, 214, 205, 22], ["+", 8, 196, 0, 1, 0, 213, 63, 214, 0, 131], ["+", 8, 196, 0, 1, 0, 213, 63, 214, 141, 22], ["+", 8, 196, 0, 1, 0, 213, 3, 4, 0, 24], ["+", 8, 196, 0, 1, 0, 213, 3, 4, 0, 25], ["+", 8, 196, 0, 7, 8, 196, 0, 1, 0, 35]]
| 8
| 129
| 6
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.