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
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace AGC011Airport { class Program { static void Main(string[] args) { int N, C, K; string[] vals = Console.ReadLine().Split(' '); N = int.Parse(vals[0]); C = int.Parse(vals[1]); ...
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace AGC011Airport { class Program { static void Main(string[] args) { int N, C, K; string[] vals = Console.ReadLine().Split(' '); N = int.Parse(vals[0]); C = int.Parse(vals[1]); ...
[["+", 64, 196, 0, 7, 8, 196, 0, 57, 0, 121], ["+", 64, 196, 0, 7, 8, 196, 0, 57, 0, 24], ["+", 8, 196, 0, 57, 15, 16, 31, 214, 205, 22], ["+", 8, 196, 0, 57, 15, 16, 31, 214, 0, 131], ["+", 8, 196, 0, 57, 15, 16, 31, 214, 141, 22], ["+", 0, 7, 8, 196, 0, 57, 15, 16, 17, 60], ["+", 0, 7, 8, 196, 0, 57, 15, 16, 12, 203]...
8
357
using System; using System.Linq; //リストの使用 using System.Collections.Generic; class Program { static void Main() { long n = long.Parse(Console.ReadLine()); long[] nums = Array.ConvertAll(Console.ReadLine().Split(' '), long.Parse); long[] sums = new long[n]; // iまでの和 long answer = 1; sums[0] = nums[...
using System; using System.Linq; //リストの使用 using System.Collections.Generic; class Program { static void Main() { long n = long.Parse(Console.ReadLine()); long[] nums = Array.ConvertAll(Console.ReadLine().Split(' '), long.Parse); Array.Sort(nums); //ソート long[] sums = new long[n]; // iまでの和 ...
[["+", 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], ["+", 0, 1, 0, 213, 3, 4, 0, 28, 0, 22], ["+", 8, 196, 0, 1, 0, 213, 3, 4, 0, 25], ["+", 8, 201, 0, 195, 8, 196, 0, 1, 0, 35], ["-", 10, ...
8
176
using System; using System.Collections.Generic; using System.Linq; class Program { static string InputPattern = "InputX"; static List<string> GetInputList() { var WillReturn = new List<string>(); if (InputPattern == "Input1") { WillReturn.Add("3"); WillReturn.Add("3 1 4"); // 2 } el...
using System; using System.Collections.Generic; using System.Linq; class Program { static string InputPattern = "InputX"; static List<string> GetInputList() { var WillReturn = new List<string>(); if (InputPattern == "Input1") { WillReturn.Add("3"); WillReturn.Add("3 1 4"); // 2 } el...
[["-", 64, 196, 0, 1, 0, 213, 63, 214, 205, 22], ["-", 64, 196, 0, 1, 0, 213, 63, 214, 0, 131], ["-", 64, 196, 0, 1, 0, 213, 63, 214, 141, 22], ["-", 64, 196, 0, 1, 0, 213, 3, 4, 0, 24], ["-", 0, 28, 0, 16, 31, 16, 31, 214, 205, 22], ["-", 0, 28, 0, 16, 31, 16, 31, 214, 0, 131], ["-", 0, 28, 0, 16, 31, 16, 31, 214, 141...
8
334
using System; using System.Text; using System.Collections.Generic; class Solve { public Solve() {} List<int>[] G; bool[] us; bool[] b; StringBuilder sb; public static int Main() { new Solve().Run(); return 0; } void Run() { sb = new StringBuilder(); Calc(); Console.Write(sb.ToString(...
using System; using System.Text; using System.Collections.Generic; class Solve { public Solve() {} List<int>[] G; bool[] us; bool[] b; StringBuilder sb; public static int Main() { new Solve().Run(); return 0; } void Run() { sb = new StringBuilder(); Calc(); Console.Write(sb.ToString(...
[["+", 0, 195, 8, 196, 0, 197, 0, 198, 39, 199], ["+", 8, 196, 0, 197, 0, 198, 0, 200, 141, 22], ["+", 0, 197, 0, 198, 0, 200, 0, 212, 0, 32], ["+", 0, 198, 0, 200, 0, 212, 0, 211, 0, 146], ["+", 8, 201, 0, 195, 8, 196, 0, 197, 0, 35], ["-", 64, 196, 0, 57, 64, 196, 0, 37, 0, 38], ["+", 0, 57, 64, 196, 0, 1, 0, 11, 31,...
8
514
using System; using System.Linq; using System.Collections.Generic; using Debug = System.Diagnostics.Debug; using StringBuilder = System.Text.StringBuilder; using Number = System.Int64; namespace Program { public class Solver { public void Solve() { var n = sc.Integer(); var m = sc.Integer(); var a = new ...
using System; using System.Linq; using System.Collections.Generic; using Debug = System.Diagnostics.Debug; using StringBuilder = System.Text.StringBuilder; using Number = System.Int64; namespace Program { public class Solver { public void Solve() { var n = sc.Integer(); var m = sc.Integer(); var a = new ...
[["-", 0, 57, 64, 196, 0, 1, 0, 11, 31, 22], ["-", 64, 196, 0, 1, 0, 11, 0, 202, 0, 107], ["-", 0, 57, 64, 196, 0, 1, 0, 11, 12, 203], ["-", 8, 196, 0, 57, 64, 196, 0, 1, 0, 35], ["-", 0, 57, 75, 196, 0, 1, 0, 11, 31, 22], ["-", 75, 196, 0, 1, 0, 11, 0, 202, 0, 107], ["-", 0, 57, 75, 196, 0, 1, 0, 11, 12, 203], ["-", 8...
8
1,860
using System; using System.Linq; using System.Collections.Generic; using Debug = System.Diagnostics.Debug; using StringBuilder = System.Text.StringBuilder; using Number = System.Int64; namespace Program { public class Solver { public void Solve() { var n = sc.Integer(); var k = sc.Integer(); var deq = ne...
using System; using System.Linq; using System.Collections.Generic; using Debug = System.Diagnostics.Debug; using StringBuilder = System.Text.StringBuilder; using Number = System.Int64; namespace Program { public class Solver { public void Solve() { var n = sc.Integer(); var k = sc.Integer(); var deq = ne...
[["-", 8, 196, 0, 1, 0, 11, 0, 202, 0, 132], ["+", 8, 196, 0, 1, 0, 11, 0, 202, 0, 32], ["+", 0, 1, 0, 11, 12, 213, 63, 214, 205, 22], ["+", 0, 1, 0, 11, 12, 213, 63, 214, 0, 131], ["+", 0, 1, 0, 11, 12, 213, 63, 214, 141, 22], ["+", 0, 1, 0, 11, 12, 213, 3, 4, 0, 24], ["+", 0, 11, 12, 213, 3, 4, 0, 28, 0, 22], ["+", 0...
8
1,892
using System; using System.Text; using System.Collections.Generic; class Solve { public Solve() {} StringBuilder sb; public static int Main() { new Solve().Run(); return 0; } void Run() { sb = new StringBuilder(); Calc(); Console.Write(sb.ToString()); } void Calc() { string[] str =...
using System; using System.Text; using System.Collections.Generic; class Solve { public Solve() {} StringBuilder sb; public static int Main() { new Solve().Run(); return 0; } void Run() { sb = new StringBuilder(); Calc(); Console.Write(sb.ToString()); } void Calc() { string[] str =...
[["+", 8, 196, 0, 57, 15, 16, 31, 204, 205, 22], ["+", 0, 57, 15, 16, 31, 204, 206, 207, 0, 70], ["+", 0, 57, 15, 16, 31, 204, 206, 207, 0, 73], ["+", 8, 196, 0, 57, 15, 16, 12, 204, 205, 22], ["+", 0, 57, 15, 16, 12, 204, 206, 207, 0, 70], ["+", 0, 57, 15, 16, 12, 204, 206, 207, 0, 73]]
8
2,189
using System; using System.Collections.Generic; class Program { static void Main(string[] args) { string str = Console.ReadLine(); long N = long.Parse(str); string[] str2 = Console.ReadLine().Split(); long[] X = new long[N]; for (var i = 0; i < N; i++) { X[i] = long.Parse(str2[i]); } ...
using System; using System.Collections.Generic; class Program { static void Main(string[] args) { string str = Console.ReadLine(); long N = long.Parse(str); string[] str2 = Console.ReadLine().Split(); long[] X = new long[N]; for (var i = 0; i < N; i++) { X[i] = long.Parse(str2[i]); } ...
[["-", 8, 196, 0, 7, 8, 196, 0, 7, 0, 88], ["+", 8, 196, 0, 7, 8, 196, 0, 52, 0, 89], ["-", 8, 196, 0, 7, 10, 198, 39, 216, 0, 217], ["-", 8, 196, 0, 7, 10, 198, 0, 200, 141, 22], ["-", 0, 7, 10, 198, 0, 200, 0, 212, 0, 32], ["-", 8, 196, 0, 7, 8, 196, 0, 7, 0, 35], ["-", 0, 7, 8, 196, 0, 7, 15, 16, 31, 22], ["-", 0, 7...
8
227
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace Mujin { class Program { static void Main(string[] args) { var N = int.Parse(Console.ReadLine()); var x = Console.ReadLine().Split(' ').Select(y => int.Parse(y)).ToArray(); long co...
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace Mujin { class Program { static void Main(string[] args) { var N = int.Parse(Console.ReadLine()); var x = Console.ReadLine().Split(' ').Select(y => int.Parse(y)).ToArray(); long co...
[["-", 0, 200, 0, 212, 0, 230, 39, 236, 141, 22], ["+", 0, 200, 0, 212, 0, 230, 39, 236, 141, 22], ["-", 0, 212, 0, 74, 51, 23, 0, 16, 31, 203], ["-", 0, 212, 0, 74, 51, 23, 0, 16, 17, 72], ["-", 0, 212, 0, 74, 51, 23, 0, 16, 12, 203], ["+", 0, 200, 0, 212, 0, 74, 51, 23, 0, 203], ["-", 8, 196, 0, 1, 0, 213, 63, 214, 1...
8
219
using System; class Program { static void Main() { long n = long.Parse(Console.ReadLine()); // int.Parseは文字列を整数に変換。 long pow = 1; for (int i = 1; i <= n; i++) { pow *= i; } //出力 Console.WriteLine(pow % 1000000007); // WriteLineをWriteとすると、改行なしで出力。 } }
using System; class Program { static void Main() { long n = long.Parse(Console.ReadLine()); // int.Parseは文字列を整数に変換。 long pow = 1; for (int i = 1; i <= n; i++) { pow *= i; while (pow > 1000000007) pow -= 1000000007; } //出力 Console.WriteLine(pow % 10000...
[["+", 8, 196, 0, 7, 8, 196, 0, 52, 0, 89], ["+", 8, 196, 0, 7, 8, 196, 0, 52, 0, 24], ["+", 0, 7, 8, 196, 0, 52, 15, 16, 31, 22], ["+", 0, 7, 8, 196, 0, 52, 15, 16, 17, 47], ["+", 0, 7, 8, 196, 0, 52, 15, 16, 12, 203], ["+", 8, 196, 0, 7, 8, 196, 0, 52, 0, 25], ["+", 8, 196, 0, 52, 8, 1, 0, 11, 31, 22], ["+", 0, 52, 8...
8
65
using System; // using System.Numerics; static class Program { static void Main(string[] args) { int a = Int32.Parse(Console.ReadLine()); ulong h = 1; for (int s = 1; s <= a; s++) { h *= (ulong)s % 1000000007; } //; s = s % 1000000007; } Console.WriteLine(h); // % 1000000...
using System; class Program { static void Main(string[] args) { int a = Int32.Parse(Console.ReadLine()); ulong h = 1; for (int s = 1; s <= a; s++) { h = h * (ulong)s % 1000000007; } Console.WriteLine(h); } }
[["-", 36, 36, 0, 208, 0, 235, 0, 251, 0, 115], ["-", 8, 196, 0, 1, 0, 11, 0, 202, 0, 108], ["+", 8, 196, 0, 1, 0, 11, 0, 202, 0, 32], ["+", 0, 1, 0, 11, 12, 16, 31, 16, 31, 22], ["+", 0, 1, 0, 11, 12, 16, 31, 16, 17, 48], ["-", 8, 196, 0, 1, 0, 213, 3, 4, 0, 25], ["-", 8, 201, 0, 195, 8, 196, 0, 1, 0, 35], ["-", 8, 19...
8
79
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace AtCoder { class Program { static void Main(string[] args) { var N = int.Parse(Console.ReadLine()); double power = 1; for (int i = 1; i <= N; i++) { power *= i % (Math.Pow(10...
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace AtCoder { class Program { static void Main(string[] args) { var N = int.Parse(Console.ReadLine()); long power = 1; for (int i = 1; i <= N; i++) { power *= i; power %= ...
[["-", 0, 195, 8, 196, 0, 197, 0, 198, 39, 199], ["+", 0, 195, 8, 196, 0, 197, 0, 198, 39, 199], ["-", 8, 196, 0, 1, 0, 11, 12, 16, 17, 109], ["+", 8, 196, 0, 7, 8, 196, 0, 1, 0, 35], ["+", 0, 7, 8, 196, 0, 1, 0, 11, 31, 22], ["+", 8, 196, 0, 1, 0, 11, 0, 202, 0, 132], ["+", 8, 196, 0, 1, 0, 11, 12, 74, 0, 24], ["+", 8...
8
105
using System; using System.Collections.Generic; using System.Linq; namespace at { class Program { static void Main(string[] args) { var x = 0; var N = int.Parse(Console.ReadLine()); var s = Console.ReadLine(); var a = new List<int>() { 0 }; for (int i = 0; i < N; i++) { Console.WriteLine(s...
using System; using System.Collections.Generic; using System.Linq; namespace at { class Program { static void Main(string[] args) { var x = 0; var N = int.Parse(Console.ReadLine()); var s = Console.ReadLine(); var a = new List<int>() { 0 }; for (int i = 0; i < N; i++) { if ((s[i]).ToString...
[["-", 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], ["-", 0, 213, 3, 4, 0, 28, 0, 204, 205, 22], ["-", 3, 4, 0, 28, 0, 204, 206, 207, 0, 70], ["-", 0, 28, 0, 204, 206, 207, 0, 28, 0, 22], [...
8
169
using System; using System.Linq; using System.Collections.Generic; using System.Text.RegularExpressions; using System.Text; public class Program { public void Proc() { Reader.IsDebug = false; int x = 0; int ans = 0; string cmd = Reader.ReadLine(); foreach (char c in cmd) { if (c == 'D') { ...
using System; using System.Linq; using System.Collections.Generic; using System.Text.RegularExpressions; using System.Text; public class Program { public void Proc() { Reader.IsDebug = false; int x = 0; int ans = 0; int cnt = int.Parse(Reader.ReadLine()); string cmd = Reader.ReadLine(); forea...
[["+", 0, 195, 8, 196, 0, 197, 0, 198, 39, 199], ["+", 8, 196, 0, 197, 0, 198, 0, 200, 141, 22], ["+", 0, 197, 0, 198, 0, 200, 0, 212, 0, 32], ["+", 0, 200, 0, 212, 0, 213, 63, 214, 205, 199], ["+", 0, 200, 0, 212, 0, 213, 63, 214, 0, 131], ["+", 0, 200, 0, 212, 0, 213, 63, 214, 141, 22], ["+", 0, 200, 0, 212, 0, 213, ...
8
219
using System; namespace abc_B { class Program { static void Main(string[] args) { int h = int.Parse(Console.ReadLine()); int[] j = new int[h]; string kl = Console.ReadLine(); string imaw; int imamade = 0; for (int q = 0; q < h; q++) { imaw = (kl.Substring(q, 1)); if (imaw == "D") ...
using System; class Program { static void Main(string[] args) { int h = int.Parse(Console.ReadLine()); int[] j = new int[h]; string kl = Console.ReadLine(); string imaw; int imamade = 0; for (int q = 0; q < h; q++) { imaw = (kl.Substring(q, 1)); if (imaw == "D") { imamade ...
[["-", 36, 36, 36, 36, 0, 208, 0, 209, 0, 256], ["-", 36, 36, 36, 36, 0, 208, 0, 209, 141, 22], ["-", 36, 36, 0, 208, 0, 209, 8, 201, 0, 45], ["+", 8, 201, 0, 195, 8, 196, 0, 57, 0, 121], ["+", 8, 201, 0, 195, 8, 196, 0, 57, 0, 24], ["+", 8, 196, 0, 57, 15, 16, 31, 204, 205, 22], ["+", 0, 57, 15, 16, 31, 204, 206, 207,...
8
140
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace ConsoleApplication54 { class Program { static void Main(string[] args) { int a = int.Parse(Console.ReadLine()); string b = Console.ReadLine(); int[] e = new int[a + 1]; int d ...
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace ConsoleApplication54 { class Program { static void Main(string[] args) { int a = int.Parse(Console.ReadLine()); string b = Console.ReadLine(); int[] e = new int[a + 1]; int d ...
[["-", 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], ["-", 0, 1, 0, 213, 3, 4, 0, 28, 0, 22], ["-", 8, 196, 0, 1, 0, 213, 3, 4, 0, 25], ["-", 8, 196, 0, 7, 8, 196, 0, 1, 0, 35]]
8
175
using System; using System.Collections.Generic; namespace kozaiyApp { public class FactorsOfFactorial { static void Main() { int N = int.Parse(Console.ReadLine()); Dictionary<int, int> count = new Dictionary<int, int>(); // 素数xが何個あるか int mod = 1000000007; for (int i = 1; i <= N; i++) // N!.....
using System; using System.Collections.Generic; namespace kozaiyApp { public class FactorsOfFactorial { static void Main() { long N = int.Parse(Console.ReadLine()); Dictionary<long, long> count = new Dictionary<long, long>(); // 素数xが何個あるか long mod = 1000000007; for (long i = 2; i <= N; i++) ...
[["-", 0, 195, 8, 196, 0, 197, 0, 198, 39, 199], ["+", 0, 195, 8, 196, 0, 197, 0, 198, 39, 199], ["-", 0, 197, 0, 198, 39, 236, 237, 238, 0, 199], ["+", 0, 197, 0, 198, 39, 236, 237, 238, 0, 199], ["-", 0, 212, 0, 230, 39, 236, 237, 238, 0, 199], ["+", 0, 212, 0, 230, 39, 236, 237, 238, 0, 199], ["-", 0, 195, 8, 196, 0...
8
247
using System; using System.Collections.Generic; namespace ABC052 { class Program { const int N = 1000000000; static Dictionary<int, int> dic; static void Main(string[] args) { dic = new Dictionary<int, int>(); int n = int.Parse(Console.ReadLine()); ulong num = 1; for (int i = 1; i <= n; i++) { ...
using System; using System.Collections.Generic; namespace ABC052 { class Program { const int N = 1000000000; static Dictionary<int, int> dic; static void Main(string[] args) { dic = new Dictionary<int, int>(); int n = int.Parse(Console.ReadLine()); ulong num = 1; for (int i = 1; i <= n; i++) { ...
[["-", 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], ["-", 0, 28, 0, 16, 31, 16, 31, 214, 205, 22], ["-", 0, 28, 0, 16, 31, 16, 31, 214, 0, 131], ["-", 0, 28, 0, 16, 31, 16, 31, 214, 141, 22...
8
238
using System; using System.Linq; class Program { static void Main(string[] args) { string s = Console.ReadLine(); string ans = s.Replace('.', ' '); Console.WriteLine(ans); } }
using System; using System.Linq; class Program { static void Main(string[] args) { string s = Console.ReadLine().Replace(',', ' '); Console.WriteLine(s); } }
[["-", 8, 201, 0, 195, 8, 196, 0, 197, 0, 35], ["-", 0, 195, 8, 196, 0, 197, 0, 198, 39, 199], ["-", 8, 196, 0, 197, 0, 198, 0, 200, 141, 22], ["-", 0, 197, 0, 198, 0, 200, 0, 212, 0, 32], ["-", 0, 200, 0, 212, 0, 213, 63, 214, 205, 22], ["-", 0, 213, 3, 4, 0, 28, 0, 252, 0, 253], ["+", 0, 213, 3, 4, 0, 28, 0, 252, 0, ...
8
55
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; class Program { static void Main(string[] args) { var xx = ConsoleUtil.StrArrayReadLine(); Console.WriteLine(string.Join(",", xx)); } } static class ConsoleUtil { public static string[] St...
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; class Program { static void Main(string[] args) { var xx = ConsoleUtil.StrArrayReadLine(); Console.WriteLine(string.Join(" ", xx)); } } static class ConsoleUtil { public static string[] St...
[["-", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222], ["+", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222], ["-", 0, 57, 64, 196, 0, 37, 0, 213, 63, 22], ["+", 0, 213, 63, 214, 205, 213, 63, 214, 205, 22], ["+", 0, 213, 63, 214, 205, 213, 63, 214, 0, 131], ["+", 0, 213, 63, 214, 205, 213, 63, 214, 141, 22], ["+", 0, 213, 63, 214, 205, 213, 3...
8
238
using System; namespace Atcoder { class AtCoderContest { static void Main() { string input = Console.In.ReadToEnd(); string[] S = input.Split(','); int count = S.Length - 1; string answer = ""; while (count >= 0) { answer = answer + S[count] + " "; count--; } answer = answer.Re...
using System; namespace Atcoder { class AtCoderContest { static void Main() { string input = Console.In.ReadToEnd(); string[] S = input.Split(','); int count = 0; string answer = ""; while (count <= (S.Length) - 1) { answer = answer + S[count] + " "; count++; } answer = answer....
[["-", 0, 200, 0, 212, 0, 16, 31, 214, 205, 22], ["-", 0, 200, 0, 212, 0, 16, 31, 214, 0, 131], ["-", 0, 200, 0, 212, 0, 16, 31, 214, 141, 22], ["-", 0, 198, 0, 200, 0, 212, 0, 16, 17, 33], ["-", 0, 198, 0, 200, 0, 212, 0, 16, 12, 203], ["+", 0, 197, 0, 198, 0, 200, 0, 212, 0, 203], ["-", 0, 195, 8, 196, 0, 52, 15, 16,...
8
98
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace ConsoleApp1 { class Program { static void Main(string[] args) { var ks = Array.ConvertAll(Console.ReadLine().Split(' '), int.Parse); var k = ks[0]; var s = ks[1]; var count ...
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace ConsoleApp1 { class Program { static void Main(string[] args) { var ks = Array.ConvertAll(Console.ReadLine().Split(' '), int.Parse); var k = ks[0]; var s = ks[1]; var count ...
[["+", 0, 7, 8, 196, 0, 57, 15, 16, 17, 98], ["+", 0, 57, 15, 16, 12, 16, 31, 16, 31, 22], ["+", 0, 57, 15, 16, 12, 16, 31, 16, 17, 33], ["+", 15, 16, 12, 16, 31, 16, 12, 23, 0, 24], ["+", 12, 16, 31, 16, 12, 23, 0, 16, 31, 22], ["+", 12, 16, 31, 16, 12, 23, 0, 16, 17, 72], ["+", 12, 16, 31, 16, 12, 23, 0, 16, 12, 22],...
8
148
using System; using System.IO; using System.Collections.Generic; using System.Linq; namespace AtCoder.Contest.C { static class Program { public static void Solve(Scanner cin) { long n = cin.ReadLong(); long m = cin.ReadLong(); Console.WriteLine((n * 2 + m) / 3); } public static void M...
using System; using System.IO; using System.Collections.Generic; using System.Linq; namespace AtCoder.Contest.C { static class Program { public static void Solve(Scanner cin) { long n = cin.ReadLong(); long m = cin.ReadLong(); Console.WriteLine(Math.Min((n * 2 + m) / 4, m / 2)); } pub...
[["+", 3, 4, 0, 28, 0, 213, 63, 214, 205, 22], ["+", 3, 4, 0, 28, 0, 213, 63, 214, 0, 131], ["+", 3, 4, 0, 28, 0, 213, 63, 214, 141, 22], ["+", 3, 4, 0, 28, 0, 16, 31, 23, 0, 24], ["-", 0, 213, 3, 4, 0, 28, 0, 16, 12, 203], ["+", 0, 213, 3, 4, 0, 28, 0, 16, 12, 203], ["+", 3, 4, 0, 28, 0, 213, 3, 4, 0, 21], ["+", 0, 21...
8
2,448
using System; using System.Collections.Generic; using System.Linq; namespace MyProgram { class AtCoder { static void Main() { var input = Array.ConvertAll(Console.ReadLine().Split(' '), long.Parse); long N = input[0]; long M = input[1]; long result = 0; if (2 * N < M) { result = N + (M - 2 ...
using System; using System.Collections.Generic; using System.Linq; namespace MyProgram { class AtCoder { static void Main() { var input = Array.ConvertAll(Console.ReadLine().Split(' '), long.Parse); long N = input[0]; long M = input[1]; long result = 0; if (2 * N < M) { result = N + (M - 2 ...
[["+", 0, 1, 0, 11, 12, 213, 63, 214, 205, 22], ["+", 0, 1, 0, 11, 12, 213, 63, 214, 0, 131], ["+", 0, 1, 0, 11, 12, 213, 63, 214, 141, 22], ["+", 0, 1, 0, 11, 12, 213, 3, 4, 0, 24], ["+", 0, 1, 0, 11, 12, 213, 3, 4, 0, 21], ["+", 12, 213, 3, 4, 0, 28, 0, 16, 31, 22], ["+", 12, 213, 3, 4, 0, 28, 0, 16, 17, 85], ["+", 1...
8
114
using System; using System.Text; using System.Collections.Generic; using System.Linq; public class Remainder { static public void Main() { var NM = Console.ReadLine().Split(' ').Select(x => long.Parse(x)).ToArray(); long N = NM[0]; long M = NM[1]; long ans = 0L; if (M - 2 * N >= 0) { ans =...
using System; using System.Text; using System.Collections.Generic; using System.Linq; public class Remainder { static public void Main() { var NM = Console.ReadLine().Split(' ').Select(x => long.Parse(x)).ToArray(); long N = NM[0]; long M = NM[1]; long ans = 0L; if (M - 2 * N >= 0) { ans =...
[["+", 8, 201, 0, 195, 8, 196, 0, 57, 0, 95], ["+", 0, 195, 8, 196, 0, 57, 75, 196, 0, 45], ["+", 0, 57, 75, 196, 0, 1, 0, 11, 31, 22], ["+", 75, 196, 0, 1, 0, 11, 0, 202, 0, 32], ["+", 75, 196, 0, 1, 0, 11, 12, 16, 31, 22], ["+", 75, 196, 0, 1, 0, 11, 12, 16, 17, 85], ["+", 75, 196, 0, 1, 0, 11, 12, 16, 12, 203], ["+"...
8
119
using System; using System.Linq; using System.Collections.Generic; using static System.Math; using static System.Console; using System.Text; class Program { static void Main(string[] args) { solve(); } static Scanner cin; static long N, M; static void input() { cin = new Scanner(); N = cin.nextLong()...
using System; using System.Linq; using System.Collections.Generic; using static System.Math; using static System.Console; using System.Text; class Program { static void Main(string[] args) { solve(); } static Scanner cin; static long N, M; static void input() { cin = new Scanner(); N = cin.nextLong()...
[["+", 0, 195, 8, 196, 0, 57, 15, 16, 31, 22], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 17, 19], ["-", 0, 195, 8, 196, 0, 57, 15, 16, 17, 20], ["-", 8, 196, 0, 57, 15, 16, 12, 16, 31, 203], ["-", 8, 196, 0, 57, 15, 16, 12, 16, 12, 22], ["+", 8, 196, 0, 57, 15, 16, 12, 16, 12, 203]]
8
497
using System; using System.Collections.Generic; using System.Linq; namespace AtCoder { class Program { static void Main(string[] args) { //[summary]C - Scc Puzzle var line = ReadLine(); int n = line[0]; //'s'型ピース int m = line[1]; //'c'型ピース if (m >= n * 2) { Console.WriteLine((m - n * 2) / ...
using System; using System.Collections.Generic; using System.Linq; namespace AtCoder { class Program { static void Main(string[] args) { //[summary]C - Scc Puzzle var line = ReadLine(); long s = line[0]; //'s'型ピース long c = line[1]; //'c'型ピース if (c >= s * 2) { Console.WriteLine((c - s * 2) ...
[["-", 0, 195, 8, 196, 0, 197, 0, 198, 39, 199], ["-", 8, 196, 0, 197, 0, 198, 0, 200, 141, 22], ["+", 0, 195, 8, 196, 0, 197, 0, 198, 39, 199], ["+", 8, 196, 0, 197, 0, 198, 0, 200, 141, 22], ["-", 0, 195, 8, 196, 0, 57, 15, 16, 31, 22], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 31, 22], ["-", 8, 196, 0, 57, 15, 16, 12, 16...
8
149
using System; using System.Collections.Generic; using System.Linq; using static System.Math; namespace ConsoleApp1 { class Program { static void Main(string[] args) { A(); } static void A() { var NM = ReadSplitLong(); var N = NM[0]; var M = NM[1]; var ans = 0L; M -= (N * 2); ans += N; ...
using System; using System.Collections.Generic; using System.Linq; using static System.Math; namespace ConsoleApp1 { class Program { static void Main(string[] args) { A(); } static void A() { var NM = ReadSplitLong(); var N = NM[0]; var M = NM[1]; var ans = 0L; if (N * 2 <= M) { M -= (N...
[["+", 8, 201, 0, 195, 8, 196, 0, 57, 0, 121], ["+", 8, 201, 0, 195, 8, 196, 0, 57, 0, 24], ["+", 8, 196, 0, 57, 15, 16, 31, 16, 31, 22], ["+", 8, 196, 0, 57, 15, 16, 31, 16, 17, 48], ["+", 8, 196, 0, 57, 15, 16, 31, 16, 12, 203], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 17, 19], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 12, 22...
8
668
using System; namespace ABC055_C { class Program { static void Main(string[] args) { var nm = Array.ConvertAll(Console.ReadLine().Split(' '), long.Parse); var n = nm[0]; var m = nm[1]; if (2 * n >= m) { Console.WriteLine(n); } else { var c = m - 2 * n; Console.WriteLine(n + c / ...
using System; namespace ABC055_C { class Program { static void Main(string[] args) { var nm = Array.ConvertAll(Console.ReadLine().Split(' '), long.Parse); var n = nm[0]; var m = nm[1]; if (m == 1) { Console.WriteLine(0); } else if (2 * n >= m) { Console.WriteLine(m / 2); } else { ...
[["+", 0, 195, 8, 196, 0, 57, 15, 16, 31, 22], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 17, 60], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 12, 203], ["+", 8, 201, 0, 195, 8, 196, 0, 57, 0, 25], ["+", 0, 195, 8, 196, 0, 57, 64, 196, 0, 45], ["+", 64, 196, 0, 1, 0, 213, 63, 214, 205, 22], ["+", 64, 196, 0, 1, 0, 213, 63, 214, 0, ...
8
103
using System; using System.Collections; using System.Collections.Generic; using System.Text; using static MyIO; public class C { public static void Main() { long N = GetLong(); long M = GetLong(); Console.WriteLine((2 * N >= M) ? N : N + (M - 2 * N) / 4); } } public static class MyIO { private stati...
using System; using System.Collections; using System.Collections.Generic; using System.Text; using static MyIO; public class C { public static void Main() { long N = GetLong(); long M = GetLong(); if (N >= M / 2) { Console.WriteLine(M / 2); } else { Console.WriteLine(N + (M - 2 * N) / 4)...
[["+", 8, 201, 0, 195, 8, 196, 0, 57, 0, 121], ["+", 8, 201, 0, 195, 8, 196, 0, 57, 0, 24], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 31, 22], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 17, 20], ["+", 8, 196, 0, 57, 15, 16, 12, 16, 31, 22], ["+", 8, 196, 0, 57, 15, 16, 12, 16, 17, 85], ["+", 8, 196, 0, 57, 15, 16, 12, 16, 12, 203...
8
224
#pragma warning disable using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Runtime.Serialization.Formatters.Binary; using System.Text; using System.Diagnostics; using System.Numerics; using System.Collections; static class MainClass { public static void Main() { va...
#pragma warning disable using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Runtime.Serialization.Formatters.Binary; using System.Text; using System.Diagnostics; using System.Numerics; using System.Collections; static class MainClass { public static void Main() { va...
[["-", 0, 1, 0, 213, 3, 4, 0, 28, 0, 203], ["+", 0, 213, 3, 4, 0, 28, 0, 16, 31, 22], ["+", 0, 213, 3, 4, 0, 28, 0, 16, 17, 85], ["+", 0, 213, 3, 4, 0, 28, 0, 16, 12, 203], ["-", 75, 196, 0, 57, 64, 196, 0, 37, 0, 38], ["-", 75, 196, 0, 57, 64, 196, 0, 37, 0, 35], ["-", 0, 57, 75, 196, 0, 57, 64, 196, 0, 46], ["-", 8, ...
8
1,367
using System; class Program { static void Main() { var nm = Array.ConvertAll(Console.ReadLine().Split(), long.Parse); long ans = 0; if (nm[0] <= nm[1] * 2) { ans = nm[0]; nm[1] -= nm[0] * 2; ans += nm[1] > 0 ? nm[1] / 4 : nm[1] / 2; } else ans = nm[1] / 2; Console.WriteLin...
using System; class Program { static void Main() { var nm = Array.ConvertAll(Console.ReadLine().Split(), long.Parse); long ans = 0; if (nm[0] <= nm[1] * 2) { ans = nm[0]; nm[1] -= nm[0] * 2; ans += nm[1] > 0 ? nm[1] / 4 : (long)Math.Floor((double)nm[1] / 2); } else ans = nm[1]...
[["+", 0, 1, 0, 11, 12, 41, 75, 74, 0, 24], ["+", 0, 1, 0, 11, 12, 41, 75, 74, 39, 199], ["+", 0, 1, 0, 11, 12, 41, 75, 74, 0, 25], ["+", 12, 41, 75, 74, 51, 213, 63, 214, 205, 22], ["+", 12, 41, 75, 74, 51, 213, 63, 214, 0, 131], ["+", 12, 41, 75, 74, 51, 213, 63, 214, 141, 22], ["+", 12, 41, 75, 74, 51, 213, 3, 4, 0,...
8
116
using System; using System.Linq; namespace abc_055_C { class Program { public static int a = 0; static void Main(string[] args) { int[] gf = Console.ReadLine().Split().Select(int.Parse).ToArray(); int s = gf[0], c = gf[1]; if (s * 2 < c) { Console.WriteLine(s); c -= s * 2; Console.Wri...
using System; using System.Linq; namespace abc_055_C { class Program { public static long a = 0; static void Main(string[] args) { long[] gf = Console.ReadLine().Split().Select(long.Parse).ToArray(); long s = gf[0], c = gf[1]; if (s * 2 < c) { c -= s * 2; Console.WriteLine(s + c / 4); }...
[["-", 0, 235, 8, 201, 0, 124, 0, 198, 39, 199], ["+", 0, 235, 8, 201, 0, 124, 0, 198, 39, 199], ["-", 8, 196, 0, 197, 0, 198, 39, 224, 39, 199], ["+", 8, 196, 0, 197, 0, 198, 39, 224, 39, 199], ["-", 205, 213, 3, 4, 0, 28, 0, 214, 205, 199], ["+", 205, 213, 3, 4, 0, 28, 0, 214, 205, 199], ["-", 0, 195, 8, 196, 0, 197,...
8
127
using System; using System.Linq; namespace arc069_a { class Program { static void Main(string[] args) { long[] x = Console.ReadLine().Split().Select(long.Parse).ToArray(); if (x[0] * 2 > x[1]) { Console.WriteLine(x[1] / 2); } else { Console.WriteLine(x[0] / 2 + x[1] / 4); } } } }
using System; using System.Linq; namespace arc069_a { class Program { static void Main(string[] args) { long[] x = Console.ReadLine().Split().Select(long.Parse).ToArray(); if (x[0] * 2 > x[1]) { Console.WriteLine(x[1] / 2); } else { Console.WriteLine((x[0] + x[1] / 2) / 2); } Console....
[["+", 3, 4, 0, 28, 0, 16, 31, 23, 0, 24], ["-", 3, 4, 0, 28, 0, 16, 31, 16, 17, 85], ["-", 3, 4, 0, 28, 0, 16, 31, 16, 12, 203], ["-", 3, 4, 0, 28, 0, 16, 12, 16, 12, 203], ["+", 0, 16, 31, 23, 0, 16, 12, 16, 12, 203], ["+", 3, 4, 0, 28, 0, 16, 31, 23, 0, 25], ["+", 0, 213, 3, 4, 0, 28, 0, 16, 17, 85], ["+", 0, 213, 3...
8
103
using System; using System.Collections.Generic; using System.Linq; using System.Numerics; class Program { public void Slove() { int n = int.Parse(Console.ReadLine()); bool[] testimony = Console.ReadLine().Select(x => x == 'o').ToArray(); foreach (int first in Enumerable.Range(0, 2)) foreach (int sec...
using System; using System.Collections.Generic; using System.Linq; using System.Numerics; class Program { public void Slove() { int n = int.Parse(Console.ReadLine()); bool[] testimony = Console.ReadLine().Select(x => x == 'o').ToArray(); foreach (int first in Enumerable.Range(0, 2)) foreach (int sec...
[["+", 15, 16, 31, 23, 0, 16, 31, 23, 0, 24], ["+", 12, 23, 0, 16, 12, 204, 206, 207, 0, 73], ["+", 15, 16, 31, 23, 0, 16, 12, 23, 0, 25], ["+", 8, 196, 0, 57, 15, 16, 31, 23, 0, 25], ["+", 8, 210, 8, 196, 0, 57, 15, 16, 17, 98], ["+", 8, 196, 0, 57, 15, 16, 12, 23, 0, 24], ["+", 15, 16, 12, 23, 0, 16, 31, 23, 0, 24], ...
8
282
using System; class Program { static void Main() { int n = int.Parse(Console.ReadLine()); string s = Console.ReadLine(); string[][] arr = new string[4][]; arr[0] = new string[n]; arr[1] = new string[n]; arr[2] = new string[n]; arr[3] = new string[n]; string ans = "-1"; arr[0][1] =...
using System; class Program { static void Main() { int n = int.Parse(Console.ReadLine()); string s = Console.ReadLine(); string[][] arr = new string[4][]; arr[0] = new string[n]; arr[1] = new string[n]; arr[2] = new string[n]; arr[3] = new string[n]; string ans = "-1"; arr[0][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], ["+", 0, 213, 3, 4, 0, 28, 0, 5, 0, 62], ["+", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222], ["+", 8, 196, 0, 1, 0, 213, 3, 4, 0, 21], ["+", 0, 1, ...
8
789
using System; using System.Collections; using System.Collections.Generic; using System.Diagnostics; using System.IO; using System.Linq; using System.Linq.Expressions; using System.Runtime.InteropServices; using System.Runtime.Remoting.Messaging; using System.Security.Principal; using System.Text; class Simple { int N...
using System; using System.Collections; using System.Collections.Generic; using System.Diagnostics; using System.IO; using System.Linq; using System.Linq.Expressions; using System.Runtime.InteropServices; using System.Runtime.Remoting.Messaging; using System.Security.Principal; using System.Text; class Simple { int N...
[["-", 8, 196, 0, 197, 0, 198, 39, 216, 0, 217], ["-", 8, 196, 0, 197, 0, 198, 0, 200, 141, 22], ["-", 0, 197, 0, 198, 0, 200, 0, 212, 0, 32], ["-", 0, 198, 0, 200, 0, 212, 0, 230, 0, 228], ["-", 0, 212, 0, 230, 39, 232, 234, 232, 234, 22], ["-", 0, 212, 0, 230, 39, 232, 234, 232, 0, 131], ["-", 0, 212, 0, 230, 39, 232...
8
871
// dryしたいがまず提出 using System; namespace AtCoder { class CircleList<T> { T[] circle_list; public int Length { get { return circle_list.Length; } } public CircleList(int length) { circle_list = new T[length]; } public CircleList(T[] char_array) { circle_list = char_array; } public T this[int index] {...
using System; namespace AtCoder { class CircleList<T> { T[] circle_list; public int Length { get { return circle_list.Length; } } public CircleList(int length) { circle_list = new T[length]; } public CircleList(T[] char_array) { circle_list = char_array; } public T this[int index] { get { retur...
[["+", 8, 201, 0, 195, 8, 196, 0, 57, 0, 121], ["+", 8, 201, 0, 195, 8, 196, 0, 57, 0, 24], ["+", 8, 201, 0, 195, 8, 196, 0, 57, 0, 25], ["+", 0, 195, 8, 196, 0, 57, 64, 37, 0, 38], ["+", 8, 196, 0, 57, 15, 213, 3, 4, 0, 25], ["-", 8, 201, 0, 235, 8, 201, 0, 195, 39, 199], ["+", 8, 201, 0, 235, 8, 201, 0, 195, 39, 199]...
8
657
using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Net; using static System.Console; using static System.Math; using static CS_Contest.Utils; using System.Numerics; using System.Linq.Expressions; using Nakov.IO; using static Nakov.IO.Cin; // using static CS_Contest.Library...
using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Net; using static System.Console; using static System.Math; using static CS_Contest.Utils; using System.Numerics; using System.Linq.Expressions; using Nakov.IO; using static Nakov.IO.Cin; // using static CS_Contest.Library...
[["-", 0, 195, 8, 196, 0, 197, 0, 198, 39, 199], ["+", 0, 195, 8, 196, 0, 197, 0, 198, 39, 199], ["-", 0, 198, 0, 200, 0, 212, 0, 213, 63, 22], ["+", 0, 198, 0, 200, 0, 212, 0, 213, 63, 22], ["-", 8, 201, 0, 195, 8, 196, 0, 52, 0, 89], ["+", 0, 195, 8, 196, 0, 1, 0, 11, 31, 22], ["+", 8, 196, 0, 1, 0, 11, 0, 202, 0, 10...
8
1,404
using System; using System.IO; using System.Collections.Generic; namespace ARC069C { public class Program { void Solve(StreamScanner ss, StreamWriter sw) { //--------------------------------- var N = ss.Next(long.Parse); var M = ss.Next(long.Parse); sw.WriteLine(N + Math.Max(0, M - N * 2) / 4); /...
using System; using System.IO; using System.Collections.Generic; namespace ARC069C { public class Program { void Solve(StreamScanner ss, StreamWriter sw) { //--------------------------------- var N = ss.Next(long.Parse); var M = ss.Next(long.Parse); sw.WriteLine(Math.Min(N, M / 2) + Math.Max(0, M - N...
[["+", 0, 28, 0, 16, 31, 213, 63, 214, 205, 22], ["+", 0, 28, 0, 16, 31, 213, 63, 214, 0, 131], ["+", 0, 28, 0, 16, 31, 213, 63, 214, 141, 22], ["+", 0, 28, 0, 16, 31, 213, 3, 4, 0, 24], ["+", 0, 28, 0, 16, 31, 213, 3, 4, 0, 21], ["+", 31, 213, 3, 4, 0, 28, 0, 16, 31, 22], ["+", 31, 213, 3, 4, 0, 28, 0, 16, 17, 85], ["...
8
281
using System; using System.Collections; using System.Collections.Generic; using System.Linq; namespace AtCoder20170211 { class Program { static void Main(string[] args) { var input = Console.ReadLine().Split(' '); var s = Convert.ToDecimal(input[0]); var c = Convert.ToDecimal(input[1]); var scc = 0...
using System; using System.Collections; using System.Collections.Generic; using System.Linq; namespace AtCoder20170211 { class Program { static void Main(string[] args) { var input = Console.ReadLine().Split(' '); var s = Convert.ToDecimal(input[0]); var c = Convert.ToDecimal(input[1]); var scc = 0...
[["-", 0, 57, 75, 196, 0, 1, 0, 11, 31, 22], ["-", 75, 196, 0, 1, 0, 11, 0, 202, 0, 110], ["-", 0, 57, 75, 196, 0, 1, 0, 11, 12, 22], ["-", 8, 196, 0, 57, 75, 196, 0, 1, 0, 35], ["-", 75, 196, 0, 1, 0, 11, 0, 202, 0, 107], ["-", 0, 1, 0, 11, 12, 213, 63, 214, 205, 22], ["-", 0, 1, 0, 11, 12, 213, 63, 214, 0, 131], ["-"...
8
153
using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace ARC069 { public class C { private void Run() { var input = Console.ReadLine().Trim().Split(); var s = long.Parse(input[0]); var c = long.Parse(input[1]); Console.WriteLine((c + s * 2) / 4); } public s...
using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace ARC069 { public class C { private void Run() { var input = Console.ReadLine().Trim().Split(); var s = long.Parse(input[0]); var c = long.Parse(input[1]); long t = Math.Min(s, c / 2); Console.WriteLine...
[["+", 0, 195, 8, 196, 0, 197, 0, 198, 39, 199], ["+", 8, 196, 0, 197, 0, 198, 0, 200, 141, 22], ["+", 0, 197, 0, 198, 0, 200, 0, 212, 0, 32], ["+", 0, 200, 0, 212, 0, 213, 63, 214, 205, 22], ["+", 0, 200, 0, 212, 0, 213, 63, 214, 0, 131], ["+", 0, 200, 0, 212, 0, 213, 63, 214, 141, 22], ["+", 0, 200, 0, 212, 0, 213, 3...
8
166
using System; using System.Collections; using System.Collections.Generic; using System.Diagnostics; using System.Globalization; using System.IO; using System.Text; using System.Linq; using E = System.Linq.Enumerable; internal partial class Solver { public void Run() { var n = ni(); var s = ns(); cout.W...
using System; using System.Collections; using System.Collections.Generic; using System.Diagnostics; using System.Globalization; using System.IO; using System.Text; using System.Linq; using E = System.Linq.Enumerable; internal partial class Solver { public void Run() { var n = ni(); var s = ns(); cout.W...
[["+", 8, 196, 0, 7, 15, 16, 12, 16, 17, 72], ["+", 8, 196, 0, 7, 15, 16, 12, 16, 12, 203], ["+", 31, 204, 206, 207, 0, 28, 0, 16, 17, 109], ["+", 206, 207, 0, 28, 0, 16, 12, 214, 205, 22], ["+", 206, 207, 0, 28, 0, 16, 12, 214, 0, 131], ["+", 206, 207, 0, 28, 0, 16, 12, 214, 141, 22], ["-", 3, 4, 0, 28, 0, 41, 64, 252...
8
1,298
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace AtCoderRegularContest069 { public class Program { static void Main(string[] args) { Console.WriteLine( program1(new String[] { Console.ReadLine(), Console.ReadLine() })); } p...
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace AtCoderRegularContest069 { public class Program { static void Main(string[] args) { Console.WriteLine( program1(new String[] { Console.ReadLine(), Console.ReadLine() })); } p...
[["-", 0, 28, 0, 218, 8, 196, 0, 37, 0, 38], ["-", 0, 37, 0, 16, 31, 213, 63, 214, 205, 22], ["-", 0, 37, 0, 16, 31, 213, 63, 214, 0, 131], ["-", 0, 37, 0, 16, 31, 213, 63, 214, 141, 22], ["-", 0, 37, 0, 16, 31, 213, 3, 4, 0, 24], ["-", 0, 37, 0, 16, 31, 213, 3, 4, 0, 25], ["-", 0, 218, 8, 196, 0, 37, 0, 16, 17, 60], [...
8
416
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Text.RegularExpressions; using static System.Console; using static System.Math; using static MyIO; using static MyUtil; public class E { public static void Main() => (new Solver()).Solve(); } public class Solver { p...
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Text.RegularExpressions; using static System.Console; using static System.Math; using static MyIO; using static MyUtil; public class E { public static void Main() => (new Solver()).Solve(); } public class Solver { p...
[["+", 0, 195, 8, 196, 0, 197, 0, 198, 39, 199], ["+", 8, 196, 0, 197, 0, 198, 0, 200, 141, 22], ["+", 0, 197, 0, 198, 0, 200, 0, 212, 0, 32], ["+", 0, 198, 0, 200, 0, 212, 0, 214, 205, 199], ["+", 0, 198, 0, 200, 0, 212, 0, 214, 0, 131], ["+", 0, 198, 0, 200, 0, 212, 0, 214, 141, 22], ["+", 8, 201, 0, 195, 8, 196, 0, ...
8
893
using System; using System.Linq; using System.Collections.Generic; namespace Contest { class Program { static void Main(string[] args) { ARC069.E(); } class ARC069 { public static void C() { var N = Read.Long(); var M = Read.Long(); long scc1 = Math.Min(N, M / 2); long scc2 = (M - scc1 ...
using System; using System.Linq; using System.Collections.Generic; namespace Contest { class Program { static void Main(string[] args) { ARC069.E(); } class ARC069 { public static void C() { var N = Read.Long(); var M = Read.Long(); long scc1 = Math.Min(N, M / 2); long scc2 = (M - scc1 ...
[["+", 0, 1, 0, 11, 12, 16, 12, 23, 0, 24], ["+", 12, 16, 12, 23, 0, 41, 15, 16, 31, 22], ["+", 12, 16, 12, 23, 0, 41, 15, 16, 17, 47], ["+", 12, 16, 12, 23, 0, 41, 15, 16, 12, 203], ["+", 0, 11, 12, 16, 12, 23, 0, 41, 0, 101], ["+", 0, 11, 12, 16, 12, 23, 0, 41, 0, 102], ["+", 0, 11, 12, 16, 12, 23, 0, 41, 75, 203], [...
8
1,963
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.IO; static class Program { const int mod = 1000000007; static void Main() { Sc sc = new Sc(); int n = sc.I; int[] a = sc.Ia; var hs = new SortedDictionary<int, int[]> { [0] = new int[] { 0, 0 } }; ...
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.IO; static class Program { const int mod = 1000000007; static void Main() { Sc sc = new Sc(); int n = sc.I; int[] a = sc.Ia; var hs = new SortedDictionary<int, int[]> { [0] = new int[] { -1, 0 } }; ...
[["-", 10, 229, 0, 11, 12, 227, 0, 229, 0, 203], ["+", 0, 11, 12, 227, 0, 229, 0, 241, 0, 33], ["+", 0, 11, 12, 227, 0, 229, 0, 241, 0, 203], ["-", 0, 197, 0, 198, 0, 200, 0, 212, 0, 203], ["+", 0, 198, 0, 200, 0, 212, 0, 214, 205, 199], ["+", 0, 198, 0, 200, 0, 212, 0, 214, 0, 131], ["+", 0, 198, 0, 200, 0, 212, 0, 21...
8
531
using System; using System.Collections.Generic; using System.Linq; using System.Linq.Expressions; using System.IO; using System.Text; using System.Diagnostics; using Binary = System.Func<System.Linq.Expressions.ParameterExpression, System.Linq.Expressions.ParameterExpression, ...
using System; using System.Collections.Generic; using System.Linq; using System.Linq.Expressions; using System.IO; using System.Text; using System.Diagnostics; using Binary = System.Func<System.Linq.Expressions.ParameterExpression, System.Linq.Expressions.ParameterExpression, ...
[["+", 0, 57, 64, 196, 0, 197, 0, 198, 39, 199], ["+", 64, 196, 0, 197, 0, 198, 0, 200, 141, 22], ["+", 0, 197, 0, 198, 0, 200, 0, 212, 0, 32], ["+", 0, 200, 0, 212, 0, 213, 63, 214, 205, 22], ["+", 0, 200, 0, 212, 0, 213, 63, 214, 0, 131], ["+", 0, 200, 0, 212, 0, 213, 63, 214, 141, 22], ["+", 0, 200, 0, 212, 0, 213, ...
8
3,540
using System; using System.Collections.Generic; using System.Linq; using System.IO; using System.Globalization; using System.Diagnostics; using static System.Console; using Pair = System.Collections.Generic.KeyValuePair<int, int>; class Program { static void Main() { SetOut(new StreamWriter(OpenStandardOutput())...
using System; using System.Collections.Generic; using System.Linq; using System.IO; using System.Globalization; using System.Diagnostics; using static System.Console; using Pair = System.Collections.Generic.KeyValuePair<int, int>; class Program { static void Main() { SetOut(new StreamWriter(OpenStandardOutput())...
[["+", 0, 1, 0, 11, 12, 16, 12, 23, 0, 24], ["+", 12, 23, 0, 16, 31, 213, 3, 4, 0, 25], ["+", 0, 11, 12, 16, 12, 23, 0, 16, 17, 33], ["+", 12, 16, 12, 23, 0, 16, 12, 204, 205, 22], ["+", 12, 23, 0, 16, 12, 204, 206, 207, 0, 70], ["+", 0, 16, 12, 204, 206, 207, 0, 28, 0, 203], ["+", 12, 23, 0, 16, 12, 204, 206, 207, 0, ...
8
562
using System; using System.Collections; using System.Collections.Generic; using System.Diagnostics; using System.IO; using System.Linq; // using System.Numerics; //comment out if AOJ using System.Text; using Problem = Tmp.Problem; using MyIO; #pragma warning disable // for AOJ namespace Tmp { class Problem : IDispo...
using System; using System.Collections; using System.Collections.Generic; using System.Diagnostics; using System.IO; using System.Linq; // using System.Numerics; //comment out if AOJ using System.Text; using Problem = Tmp.Problem; using MyIO; #pragma warning disable // for AOJ namespace Tmp { class Problem : IDispo...
[["+", 0, 195, 8, 196, 0, 197, 0, 198, 39, 199], ["+", 8, 196, 0, 197, 0, 198, 0, 200, 141, 22], ["+", 0, 197, 0, 198, 0, 200, 0, 212, 0, 32], ["+", 0, 198, 0, 200, 0, 212, 0, 16, 31, 22], ["+", 0, 198, 0, 200, 0, 212, 0, 16, 17, 33], ["+", 0, 198, 0, 200, 0, 212, 0, 16, 12, 203], ["+", 8, 201, 0, 195, 8, 196, 0, 197, ...
8
1,541
using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace ARC069 { public class E { private void Run() { var N = int.Parse(Console.ReadLine().Trim()); var A = Console.ReadLine() .Trim() .Split() .Select((s, i) => new { inde...
using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace ARC069 { public class E { private void Run() { var N = int.Parse(Console.ReadLine().Trim()); var A = Console.ReadLine() .Trim() .Split() .Select((s, i) => new { inde...
[["-", 8, 196, 0, 197, 0, 198, 0, 200, 141, 22], ["-", 0, 197, 0, 198, 0, 200, 0, 212, 0, 32], ["-", 0, 200, 0, 212, 0, 214, 205, 204, 205, 22], ["-", 0, 212, 0, 214, 205, 204, 206, 207, 0, 70], ["-", 0, 214, 205, 204, 206, 207, 0, 28, 0, 203], ["-", 0, 212, 0, 214, 205, 204, 206, 207, 0, 73], ["-", 0, 198, 0, 200, 0, ...
8
407
using System; namespace abc054A { class MainClass { public static void Main(string[] args) { string[] str = Console.ReadLine().Split(); int A = int.Parse(str[0]); int B = int.Parse(str[1]); if (A > B && B != 1) Console.WriteLine("Alice"); else if (A < B && A != 1) Console.WriteLine("B...
using System; namespace abc054A { class MainClass { public static void Main(string[] args) { string[] str = Console.ReadLine().Split(); int A = int.Parse(str[0]); int B = int.Parse(str[1]); if (A > B && B != 1) Console.WriteLine("Alice"); else if (A < B && A != 1) Console.WriteLine("B...
[["-", 0, 57, 75, 57, 75, 57, 15, 16, 12, 203], ["+", 0, 57, 75, 57, 75, 57, 15, 16, 12, 22], ["-", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222], ["+", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222], ["-", 75, 57, 75, 57, 75, 57, 15, 16, 31, 22], ["+", 75, 57, 75, 57, 75, 57, 15, 16, 31, 22], ["-", 75, 57, 75, 57, 75, 57, 15, 16, 17, 60], [...
8
151
using System; using System.Collections; using System.Collections.Generic; using System.Linq; using System.Text; using Console = System.Console; namespace Atcoder { class Program { static void Main(string[] args) { var AB = ReadIntArray(); if (AB[0] == AB[1]) { Console.WriteLine("Draw"); } else if (...
using System; using System.Collections; using System.Collections.Generic; using System.Linq; using System.Text; using Console = System.Console; namespace Atcoder { class Program { static void Main(string[] args) { var AB = ReadIntArray(); if (AB[0] == AB[1]) { Console.WriteLine("Draw"); } else if (...
[["+", 0, 57, 75, 57, 15, 16, 12, 23, 0, 24], ["+", 75, 57, 15, 16, 12, 23, 0, 16, 17, 98], ["+", 12, 23, 0, 16, 12, 16, 31, 204, 205, 22], ["+", 0, 16, 12, 16, 31, 204, 206, 207, 0, 70], ["+", 12, 16, 31, 204, 206, 207, 0, 28, 0, 203], ["+", 0, 16, 12, 16, 31, 204, 206, 207, 0, 73], ["+", 15, 16, 12, 23, 0, 16, 12, 16...
8
300
using System; using System.Collections.Generic; using System.Linq; using static AtCoder.Io; namespace AtCoder { class Program { static void Main() { var ab = ReadIntArray(); var a = ab[0]; var b = ab[1]; Console.WriteLine(a == b ? "Draw" : a > b ? "Alice" : "Bob"); } } public static class Io { p...
using System; using System.Collections.Generic; using System.Linq; using static AtCoder.Io; namespace AtCoder { class Program { static void Main() { var ab = ReadIntArray(); var a = ab[0]; var b = ab[1]; a = a == 1 ? 14 : a; b = b == 1 ? 14 : b; Console.WriteLine(a == b ? "Draw" : a > b ? "Al...
[["+", 0, 195, 8, 196, 0, 1, 0, 11, 31, 22], ["+", 8, 196, 0, 1, 0, 11, 0, 202, 0, 32], ["+", 0, 1, 0, 11, 12, 41, 15, 16, 31, 22], ["+", 0, 1, 0, 11, 12, 41, 15, 16, 17, 60], ["+", 0, 1, 0, 11, 12, 41, 15, 16, 12, 203], ["+", 8, 196, 0, 1, 0, 11, 12, 41, 0, 101], ["+", 8, 196, 0, 1, 0, 11, 12, 41, 64, 203], ["+", 8, 1...
8
247
using System; using System.Linq; class c { public static void Main() { int[] ab = Console.ReadLine().Split(' ').Select(int.Parse).ToArray(); int a = ab[0]; int b = ab[1]; if ((a > b && b != 1) || (a == 1)) Console.WriteLine("Alice"); else Console.WriteLine("Bob"); } }
using System; using System.Linq; class c { public static void Main() { int[] ab = Console.ReadLine().Split(' ').Select(int.Parse).ToArray(); int a = ab[0]; int b = ab[1]; if (a == b) Console.WriteLine("Draw"); else if ((a > b && b != 1) || (a == 1)) Console.WriteLine("Alice"); else...
[["+", 0, 195, 8, 196, 0, 57, 15, 16, 31, 22], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 17, 60], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 12, 22], ["+", 8, 201, 0, 195, 8, 196, 0, 57, 0, 25], ["+", 0, 57, 64, 1, 0, 213, 63, 214, 205, 22], ["+", 0, 57, 64, 1, 0, 213, 63, 214, 0, 131], ["+", 0, 57, 64, 1, 0, 213, 63, 214, 141, 2...
8
102
using System; using System.Collections.Generic; using System.Linq; using static System.Math; namespace ConsoleApp1 { class Program { static void Main(string[] args) { A(); } static void A() { var AB = ReadSplitInt(); if (AB[0] == 1) AB[0] = 14; if (AB[1] == 1) AB[1] = 14; if (AB[0] ==...
using System; using System.Collections.Generic; using System.Linq; using static System.Math; namespace ConsoleApp1 { class Program { static void Main(string[] args) { A(); } static void A() { var AB = ReadSplitInt(); if (AB[0] == 1) AB[0] = 14; if (AB[1] == 1) AB[1] = 14; if (AB[0] ==...
[["-", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222], ["+", 0, 213, 3, 4, 0, 28, 0, 5, 0, 222]]
8
759
using System; using System.Collections; using System.Collections.Generic; using System.Text; using System.Linq; public class A { public static void Main() { int a = int.Parse(Console.ReadLine()); int b = int.Parse(Console.ReadLine()); if (a == 1 || b == 1) { if (a == b) { Console.WriteLine...
using System; using System.Collections; using System.Collections.Generic; using System.Text; using System.Linq; public class Program { public static void Main() { var x = Console.ReadLine().Split(); int a = int.Parse(x[0]); int b = int.Parse(x[1]); if (a == 1 || b == 1) { if (a == b) { ...
[["-", 36, 36, 36, 36, 0, 208, 0, 235, 141, 22], ["+", 36, 36, 36, 36, 0, 208, 0, 235, 141, 22], ["-", 0, 195, 8, 196, 0, 197, 0, 198, 39, 199], ["-", 8, 196, 0, 197, 0, 198, 0, 200, 141, 22], ["+", 8, 196, 0, 197, 0, 198, 39, 216, 0, 217], ["+", 8, 196, 0, 197, 0, 198, 0, 200, 141, 22], ["-", 0, 200, 0, 212, 0, 213, 6...
8
187
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace B_007_54 { internal class Program { private static void Main(string[] args) { new Logic_A().Start(); // } public class Logic_A { public void Start() { var str = Console.Rea...
using System; namespace B_007_54 { internal class Program { private static void Main(string[] args) { new Logic_A().Start(); // } public class Logic_A { public void Start() { var str = Console.ReadLine().Split(' '); var A = Convert.ToInt32(str[0]); var B = Convert.ToInt32(str[1]); ...
[["-", 36, 36, 36, 36, 0, 208, 0, 231, 0, 233], ["-", 0, 208, 0, 231, 141, 232, 234, 232, 234, 22], ["-", 0, 208, 0, 231, 141, 232, 234, 232, 0, 131], ["-", 0, 208, 0, 231, 141, 232, 234, 232, 141, 22], ["-", 36, 36, 0, 208, 0, 231, 141, 232, 0, 131], ["-", 36, 36, 0, 208, 0, 231, 141, 232, 141, 22], ["-", 36, 36, 36, ...
8
202
using System; public class Program { static void Main(string[] args) { args = Console.ReadLine().Split(' '); int b = int.Parse(args[0]); int a = int.Parse(args[1]); a += (a == 1 ? 13 : a); b += (b == 1 ? 13 : b); Console.WriteLine(a > b ? "Alice" : a < b ? "Bob" : "Draw"); } }
using System; class Program { static void Main(string[] args) { args = Console.ReadLine().Split(' '); int a = int.Parse(args[0]); int b = int.Parse(args[1]); a = (a == 1 ? 14 : a); b = (b == 1 ? 14 : b); Console.WriteLine(a > b ? "Alice" : a < b ? "Bob" : "Draw"); } }
[["-", 36, 36, 0, 208, 0, 235, 0, 251, 0, 259], ["-", 8, 196, 0, 197, 0, 198, 0, 200, 141, 22], ["+", 8, 196, 0, 197, 0, 198, 0, 200, 141, 22], ["-", 8, 196, 0, 1, 0, 11, 0, 202, 0, 107], ["+", 8, 196, 0, 1, 0, 11, 0, 202, 0, 32], ["-", 0, 1, 0, 11, 12, 23, 0, 41, 64, 203], ["+", 0, 1, 0, 11, 12, 23, 0, 41, 64, 203]]
8
109
using System; using System.Linq; using System.Collections.Generic; using System.IO; namespace ABC { public class Program { public static void Main(string[] args) { Console.SetOut( new StreamWriter(Console.OpenStandardOutput()) { AutoFlush = false }); var ab = Console.ReadLine().Split().Select(int.Pa...
using System; using System.Linq; using System.Collections.Generic; using System.IO; namespace ABC { public class Program { public static void Main(string[] args) { Console.SetOut( new StreamWriter(Console.OpenStandardOutput()) { AutoFlush = false }); var ab = Console.ReadLine().Split().Select(int.Pa...
[["+", 0, 195, 8, 196, 0, 57, 15, 16, 17, 60], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 12, 203], ["+", 8, 201, 0, 195, 8, 196, 0, 57, 0, 25], ["+", 8, 196, 0, 57, 64, 1, 0, 11, 31, 22], ["+", 0, 57, 64, 1, 0, 11, 0, 202, 0, 32], ["+", 8, 196, 0, 57, 64, 1, 0, 11, 12, 203], ["+", 0, 195, 8, 196, 0, 57, 64, 1, 0, 35], ["+",...
8
156
using System; using System.Collections.Generic; using System.Linq; using static AtCoder.Io; namespace AtCoder { class Program { static void Main() { var nm = ReadIntArray(); var n = nm[0]; var m = nm[1]; var a = new List<string>(); var b = new List<string>(); for (var i = 0; i < n; i++) { ...
using System; using System.Collections.Generic; using System.Linq; using static AtCoder.Io; namespace AtCoder { class Program { static void Main() { var nm = ReadIntArray(); var n = nm[0]; var m = nm[1]; var a = new List<string>(); var b = new List<string>(); for (var i = 0; i < n; i++) { ...
[["+", 0, 197, 0, 198, 0, 200, 141, 22, 0, 314], ["+", 0, 197, 0, 198, 0, 200, 0, 212, 0, 32], ["+", 0, 197, 0, 198, 0, 200, 0, 212, 0, 203], ["+", 8, 196, 0, 7, 8, 196, 0, 197, 0, 35], ["+", 8, 196, 0, 197, 0, 198, 39, 216, 0, 217], ["+", 0, 200, 0, 212, 0, 213, 3, 4, 0, 21], ["+", 0, 213, 3, 4, 0, 28, 0, 22, 0, 314],...
8
416
using System; using System.Collections.Generic; using System.Linq; using System.Text; public class MainClass { public const long Giri = 1000000007; public static void Main(string[] args) { var p = Input().ToInt(); var n = p[0]; var m = p[1]; string[] a = new string[n]; string[] b = new string[...
using System; using System.Collections.Generic; using System.Linq; using System.Text; public class MainClass { public const long Giri = 1000000007; public static void Main(string[] args) { var p = Input().ToInt(); var n = p[0]; var m = p[1]; string[] a = new string[n]; string[] b = new string[...
[["+", 8, 196, 0, 7, 8, 196, 0, 57, 0, 121], ["+", 8, 196, 0, 7, 8, 196, 0, 57, 0, 24], ["+", 15, 16, 31, 16, 31, 16, 31, 16, 31, 22], ["+", 15, 16, 31, 16, 31, 16, 31, 16, 17, 72], ["+", 15, 16, 31, 16, 31, 16, 31, 16, 12, 22], ["+", 0, 57, 15, 16, 31, 16, 31, 16, 17, 33], ["+", 0, 57, 15, 16, 31, 16, 31, 16, 12, 203]...
8
520
using System; using System.Linq; using System.Collections.Generic; namespace Algorithm { class Program { static void Main(string[] args) { var l = Console.ReadLine().Split().Select(int.Parse).ToArray(); int N = l[0], M = l[1]; var A = new string[N]; var B = new string[M]; for (var i = 0; i < N;...
using System; using System.Linq; using System.Collections.Generic; namespace Algorithm { class Program { static void Main(string[] args) { var l = Console.ReadLine().Split().Select(int.Parse).ToArray(); int N = l[0], M = l[1]; var A = new string[N]; var B = new string[M]; for (var i = 0; i < N;...
[["+", 8, 196, 0, 197, 0, 198, 39, 216, 0, 217], ["+", 8, 196, 0, 197, 0, 198, 0, 200, 141, 22], ["+", 0, 197, 0, 198, 0, 200, 0, 212, 0, 32], ["+", 0, 197, 0, 198, 0, 200, 0, 212, 0, 203], ["+", 8, 201, 0, 195, 8, 196, 0, 197, 0, 35], ["-", 0, 7, 10, 198, 0, 200, 0, 212, 0, 203], ["+", 0, 7, 10, 198, 0, 200, 0, 212, 0...
8
235
using System; using System.Collections.Generic; public class Hello { public static void Main() { var array = Array.ConvertAll(Console.ReadLine().Split(' '), int.Parse); var n = array[0]; var m = array[1]; var A = new string[n]; var B = new string[m]; var Hash = new HashSet<string>(); var t...
using System; using System.Collections.Generic; public class Hello { public static void Main() { var array = Array.ConvertAll(Console.ReadLine().Split(' '), int.Parse); var n = array[0]; var m = array[1]; var A = new string[n]; var B = new string[m]; var Hash = new HashSet<string>(); var t...
[["-", 8, 196, 0, 7, 8, 196, 0, 7, 0, 88], ["-", 8, 196, 0, 7, 8, 196, 0, 7, 0, 24], ["-", 8, 196, 0, 7, 10, 198, 39, 216, 0, 217], ["-", 8, 196, 0, 7, 10, 198, 0, 200, 141, 22], ["-", 0, 7, 10, 198, 0, 200, 0, 212, 0, 32], ["-", 0, 7, 10, 198, 0, 200, 0, 212, 0, 203], ["-", 8, 196, 0, 7, 8, 196, 0, 7, 0, 35], ["-", 0,...
8
295
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace abc54 { class Program { static void Main(string[] args) { bool res = false; var inp = ScanInt; int N = inp[0]; int M = inp[1]; string[] A = new string[N]; string[] B =...
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace abc54 { class Program { static void Main(string[] args) { bool res = false; var inp = ScanInt; int N = inp[0]; int M = inp[1]; string[] A = new string[N]; string[] B =...
[["+", 8, 196, 0, 7, 8, 196, 0, 57, 0, 121], ["+", 8, 196, 0, 7, 8, 196, 0, 57, 0, 24], ["+", 0, 7, 8, 196, 0, 57, 15, 241, 0, 111], ["+", 0, 7, 8, 196, 0, 57, 15, 241, 0, 22], ["+", 8, 196, 0, 7, 8, 196, 0, 57, 0, 25], ["-", 8, 196, 0, 7, 8, 196, 0, 57, 0, 121], ["-", 8, 196, 0, 7, 8, 196, 0, 57, 0, 24], ["-", 8, 196,...
8
394
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace B_007_54 { internal class Program { private static void Main(string[] args) { new Logic_B().Start(); // } public class Logic_B { public void Start() { var hw = Console.Rea...
using System; using System.Collections.Generic; namespace B_007_54 { internal class Program { private static void Main(string[] args) { new Logic_B().Start(); // } public class Logic_B { public void Start() { var hw = Console.ReadLine().Split(' '); var ALength = Convert.ToInt32(hw[0]); ...
[["-", 36, 36, 36, 36, 0, 208, 0, 231, 0, 233], ["-", 36, 36, 0, 208, 0, 231, 141, 232, 234, 22], ["-", 36, 36, 0, 208, 0, 231, 141, 232, 0, 131], ["-", 36, 36, 0, 208, 0, 231, 141, 232, 141, 22], ["-", 36, 36, 36, 36, 0, 208, 0, 231, 0, 35], ["-", 0, 208, 0, 231, 141, 232, 234, 232, 234, 22], ["-", 0, 208, 0, 231, 141...
8
352
using System; using System.Linq; public class Program { public static void Main() { var NM = Console.ReadLine().Split().Select(int.Parse); int N = NM.First(), M = NM.Last(); var A = new string[N]; var B = new string[M]; for (int i = 0; i < N; i++) { A[i] = Console.ReadLine(); } for ...
using System; using System.Linq; public class Program { public static void Main() { var NM = Console.ReadLine().Split().Select(int.Parse); int N = NM.First(), M = NM.Last(); var A = new string[N]; var B = new string[M]; for (int i = 0; i < N; i++) { A[i] = Console.ReadLine(); } for ...
[["-", 8, 196, 0, 7, 10, 198, 0, 200, 141, 22], ["+", 8, 196, 0, 7, 10, 198, 0, 200, 141, 22], ["-", 8, 196, 0, 7, 15, 16, 31, 16, 31, 22], ["+", 8, 196, 0, 7, 15, 16, 31, 16, 31, 22], ["-", 0, 195, 8, 196, 0, 7, 15, 16, 17, 18], ["+", 0, 195, 8, 196, 0, 7, 15, 16, 17, 19], ["-", 0, 195, 8, 196, 0, 7, 26, 223, 0, 22], ...
8
251
using System; using System.Collections.Generic; using System.Linq; using System.Text.RegularExpressions; namespace ConsoleApplication { public class main { static void Main() { string[] vals = Console.ReadLine().Split(' '); int N = int.Parse(vals[0]); int M = int.Parse(vals[1]); string[] A = new stri...
using System; class TempMatch { static public void Main(string[] args) { string[] vals = Console.ReadLine().Split(' '); int N = int.Parse(vals[0]); int M = int.Parse(vals[1]); string[] A = new string[N]; string[] B = new string[M]; for (int i = 0; i < N; i++) A[i] = Console.ReadLine();...
[["-", 36, 36, 36, 36, 0, 208, 0, 231, 0, 233], ["-", 0, 208, 0, 231, 141, 232, 234, 232, 234, 22], ["-", 0, 208, 0, 231, 141, 232, 234, 232, 0, 131], ["-", 0, 208, 0, 231, 141, 232, 234, 232, 141, 22], ["-", 36, 36, 0, 208, 0, 231, 141, 232, 0, 131], ["-", 36, 36, 0, 208, 0, 231, 141, 232, 141, 22], ["-", 36, 36, 36, ...
8
281
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace abc0211 { class Program { static void Main(string[] args) { bool judge = false; string[] tmp = Console.ReadLine().Split(' '); int A_square = int.Parse(tmp[0]); int B_square = ...
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace abc0211 { class Program { static void Main(string[] args) { bool judge = false; string[] tmp = Console.ReadLine().Split(' '); int A_square = int.Parse(tmp[0]); int B_square = ...
[["+", 8, 196, 0, 57, 64, 196, 0, 57, 0, 121], ["+", 8, 196, 0, 57, 64, 196, 0, 57, 0, 24], ["+", 0, 57, 64, 196, 0, 57, 15, 16, 31, 22], ["+", 0, 57, 64, 196, 0, 57, 15, 16, 17, 60], ["+", 0, 57, 64, 196, 0, 57, 15, 16, 12, 203], ["+", 8, 196, 0, 57, 64, 196, 0, 57, 0, 25], ["+", 0, 57, 64, 196, 0, 57, 64, 196, 0, 45]...
8
323
using System; using System.Collections.Generic; using System.Text; struct coord { public int row; public int col; } class Program { public static int Main() { string[] str = Console.ReadLine().Split(' '); int N = int.Parse(str[0]); int M = int.Parse(str[1]); string[] A = new string[N]; stri...
using System; using System.Collections.Generic; using System.Text; struct coord { public int row; public int col; } class Program { public static int Main() { do { new Program().solve(); } while (false); return 0; } public void solve() { string[] str = Console.ReadLine().Split(' '); ...
[["+", 8, 201, 0, 195, 8, 196, 0, 82, 0, 170], ["+", 0, 195, 8, 196, 0, 82, 8, 196, 0, 45], ["+", 0, 1, 0, 213, 63, 214, 205, 230, 0, 228], ["+", 0, 1, 0, 213, 63, 214, 205, 230, 39, 22], ["+", 0, 213, 63, 214, 205, 230, 3, 4, 0, 24], ["+", 0, 213, 63, 214, 205, 230, 3, 4, 0, 25], ["+", 8, 196, 0, 1, 0, 213, 63, 214, 0...
8
398
using System; using System.Collections.Generic; using System.Linq; class Method { bool[] seen; int sum; int count = 0; public Method(int s, int n) { seen = new bool[n]; for (int i = 0; i < n; i++) { seen[i] = false; } sum = s; } public int get() { return count; } public void dfs(i...
using System; using System.Collections.Generic; using System.Linq; class Method { bool[] seen; int sum; int count = 0; public Method(int s, int n) { seen = new bool[n]; for (int i = 0; i < n; i++) { seen[i] = false; } sum = s; } public int get() { return count; } public void dfs(i...
[["+", 8, 196, 0, 1, 0, 11, 31, 204, 205, 22], ["+", 0, 1, 0, 11, 31, 204, 206, 207, 0, 70], ["+", 31, 204, 206, 207, 0, 28, 0, 16, 31, 22], ["+", 31, 204, 206, 207, 0, 28, 0, 16, 17, 33], ["+", 31, 204, 206, 207, 0, 28, 0, 16, 12, 203], ["+", 0, 1, 0, 11, 31, 204, 206, 207, 0, 73], ["+", 8, 196, 0, 1, 0, 11, 0, 202, 0...
8
435
using System; using System.Collections.Generic; using System.Linq; using System.IO; using System.Text; using static System.Console; using static System.Math; namespace CP { class Atria { //訪問済みかどうかを保存する配列 static bool[] vs; static long ans; static bool[,] graph; static void Main(string[] args) { int[] s =...
using System; using System.Collections.Generic; using System.Linq; using System.IO; using System.Text; using static System.Console; using static System.Math; namespace CP { class Atria { //訪問済みかどうかを保存する配列 static bool[] vs; static long ans; static bool[,] graph; static void Main(string[] args) { int[] s =...
[["+", 8, 196, 0, 1, 0, 11, 31, 204, 205, 22], ["+", 0, 1, 0, 11, 31, 204, 206, 207, 0, 70], ["+", 31, 204, 206, 207, 0, 28, 0, 204, 205, 22], ["+", 206, 207, 0, 28, 0, 204, 206, 207, 0, 70], ["+", 0, 28, 0, 204, 206, 207, 0, 28, 0, 203], ["+", 206, 207, 0, 28, 0, 204, 206, 207, 0, 73], ["+", 0, 1, 0, 11, 31, 204, 206,...
8
311
using System; namespace ABC054_C___One_Stroke_Path { class Program { static void Main(string[] args) { var NM = Array.ConvertAll(Console.ReadLine().Split(' '), int.Parse); var N = NM[0]; var M = NM[1]; var joint = new bool[N, N]; for (int i = 0; i < N; i++) for (int j = 0; j < N; j++) ...
using System; namespace ABC054_C___One_Stroke_Path { class Program { static void Main(string[] args) { var NM = Array.ConvertAll(Console.ReadLine().Split(' '), int.Parse); var N = NM[0]; var M = NM[1]; var joint = new bool[N, N]; for (int i = 0; i < N; i++) for (int j = 0; j < N; j++) ...
[["-", 0, 195, 8, 196, 0, 197, 0, 198, 39, 199], ["-", 8, 196, 0, 197, 0, 198, 0, 200, 141, 22], ["-", 0, 197, 0, 198, 0, 200, 0, 212, 0, 32], ["-", 0, 197, 0, 198, 0, 200, 0, 212, 0, 203], ["-", 8, 201, 0, 195, 8, 196, 0, 197, 0, 35], ["-", 8, 201, 0, 195, 8, 196, 0, 7, 0, 88], ["-", 8, 201, 0, 195, 8, 196, 0, 7, 0, 2...
8
457
using System; using System.Collections.Generic; using System.Linq; class Program { static Dictionary<int, List<int>> Nodes; static void Main(string[] args) { // C - One-stroke Path // https://atcoder.jp/contests/abc054/tasks/abc054_c var Array = Console.ReadLine().Split().Select(x => int.Parse(x)).ToArr...
using System; using System.Collections.Generic; using System.Linq; class Program { static Dictionary<int, List<int>> Nodes; static void Main(string[] args) { // C - One-stroke Path // https://atcoder.jp/contests/abc054/tasks/abc054_c var Array = Console.ReadLine().Split().Select(x => int.Parse(x)).ToArr...
[["+", 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], ["+", 0, 1, 0, 213, 3, 4, 0, 28, 0, 22], ["+", 8, 196, 0, 1, 0, 213, 3, 4, 0, 25], ["+", 8, 201, 0, 195, 8, 196, 0, 1, 0, 35]]
8
341
using System; using System.Linq; using System.Collections.Generic; class Program { static string[] input = Console.ReadLine().Split( ' '); // Splitで区切り文字を指定して複数個受け取る。 static int n = int.Parse(input[0]); //頂点数 static int m = int.Parse(input[1]); //辺数 static int[,] path = new int[n, n]; //隣接行列 static int...
using System; using System.Linq; using System.Collections.Generic; class Program { static string[] input = Console.ReadLine().Split( ' '); // Splitで区切り文字を指定して複数個受け取る。 static int n = int.Parse(input[0]); //頂点数 static int m = int.Parse(input[1]); //辺数 static int[,] path = new int[n, n]; //隣接行列 static int...
[["-", 8, 196, 0, 7, 8, 196, 0, 57, 0, 121], ["-", 8, 196, 0, 7, 8, 196, 0, 57, 0, 24], ["-", 8, 196, 0, 57, 15, 16, 31, 204, 205, 22], ["-", 0, 57, 15, 16, 31, 204, 206, 207, 0, 70], ["-", 15, 16, 31, 204, 206, 207, 0, 28, 0, 203], ["-", 0, 57, 15, 16, 31, 204, 206, 207, 0, 73], ["-", 0, 7, 8, 196, 0, 57, 15, 16, 17, ...
8
425
using System; using System.Collections.Generic; using System.Linq; class Program { static void Main(string[] args) { new Calc().calc(); } public class Calc { public Calc() {} public void calc() { var NM = ReadLine<int>(' '); nodes = new List<int>[NM[0]]; for (int i = 0; i < NM[0]; i++) { ...
using System; using System.Collections.Generic; using System.Linq; class Program { static void Main(string[] args) { new Calc().calc(); } public class Calc { public Calc() {} public void calc() { var NM = ReadLine<int>(' '); nodes = new List<int>[NM[0]]; for (int i = 0; i < NM[0]; i++) { ...
[["+", 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], ["+", 0, 1, 0, 213, 3, 4, 0, 28, 0, 22], ["+", 8, 196, 0, 1, 0, 213, 3, 4, 0, 25], ["+", 8, 201, 0, 195, 8, 196, 0, 1, 0, 35]]
8
730
using System; using System.Linq; using System.Collections.Generic; namespace Contest { class Program { static void Main(string[] args) { ABC054.D(); } class ABC054 { public static void A() { var A = Read.Int(); var B = Read.Int(); if (A == 1) { A = 14; } if (B == 1) { ...
using System; using System.Linq; using System.Collections.Generic; namespace Contest { class Program { static void Main(string[] args) { ABC054.D(); } class ABC054 { public static void A() { var A = Read.Int(); var B = Read.Int(); if (A == 1) { A = 14; } if (B == 1) { ...
[["-", 0, 7, 10, 198, 0, 200, 0, 212, 0, 203], ["-", 8, 196, 0, 7, 8, 196, 0, 7, 0, 35], ["-", 0, 7, 8, 196, 0, 7, 15, 16, 31, 22], ["-", 0, 7, 8, 196, 0, 7, 15, 16, 17, 19], ["-", 0, 7, 8, 196, 0, 7, 26, 241, 0, 29], ["+", 0, 7, 8, 196, 0, 7, 15, 16, 31, 22], ["+", 0, 7, 8, 196, 0, 7, 15, 16, 17, 20], ["+", 0, 7, 8, 1...
8
2,595
using System; using System.Collections; using System.Collections.Generic; using System.IO; using System.Linq; using System.Numerics; using System.Text; using System.Threading.Tasks; namespace AtCorder { public class Program { static void Main(string[] args) { var cin = new Scanner2(); int n = cin.Int(); ...
using System; using System.Collections; using System.Collections.Generic; using System.IO; using System.Linq; using System.Numerics; using System.Text; using System.Threading.Tasks; namespace AtCorder { public class Program { static void Main(string[] args) { var cin = new Scanner2(); int n = cin.Int(); ...
[["+", 64, 196, 0, 1, 0, 11, 31, 204, 205, 22], ["+", 0, 1, 0, 11, 31, 204, 206, 207, 0, 70], ["+", 31, 204, 206, 207, 0, 28, 0, 16, 31, 22], ["+", 31, 204, 206, 207, 0, 28, 0, 16, 17, 72], ["+", 31, 204, 206, 207, 0, 28, 0, 16, 12, 203], ["+", 0, 1, 0, 11, 31, 204, 206, 207, 0, 21], ["+", 0, 11, 31, 204, 206, 207, 0, ...
8
871
using System; using System.Collections.Generic; using System.Linq; using System.IO; using System.Text.RegularExpressions; using System.Text; using System.Diagnostics; using static System.Math; using static System.Array; // var input = Console.ReadLine().Split().Select(int.Parse).ToArray(); namespace AtCoderSolve { cl...
using System; using System.Collections.Generic; using System.Linq; using System.IO; using System.Text.RegularExpressions; using System.Text; using System.Diagnostics; using static System.Math; using static System.Array; // var input = Console.ReadLine().Split().Select(int.Parse).ToArray(); namespace AtCoderSolve { cl...
[["+", 8, 196, 0, 1, 0, 11, 12, 213, 63, 22], ["+", 0, 1, 0, 11, 12, 213, 3, 4, 0, 24], ["+", 0, 204, 206, 207, 0, 28, 0, 16, 17, 72], ["+", 0, 204, 206, 207, 0, 28, 0, 16, 12, 203], ["-", 8, 196, 0, 7, 8, 196, 0, 1, 0, 35], ["-", 8, 196, 0, 7, 8, 196, 0, 57, 0, 121], ["-", 8, 196, 0, 7, 8, 196, 0, 57, 0, 24], ["-", 0,...
8
696
using System; using System.Collections.Generic; using System.Linq; using static System.Console; using static System.Convert; using static System.Math; // using static System.Globalization.CultureInfo; class Program { static void Main(string[] args) { var nab = Input.ar; const int LI = 401; var abc = new ...
using System; using System.Collections.Generic; using System.Linq; using static System.Console; using static System.Convert; using static System.Math; // using static System.Globalization.CultureInfo; class Program { static void Main(string[] args) { var nab = Input.ar; const int LI = 401; var abc = new ...
[["-", 0, 7, 10, 198, 0, 200, 0, 212, 0, 203], ["+", 0, 7, 10, 198, 0, 200, 0, 212, 0, 203], ["-", 8, 196, 0, 7, 8, 196, 0, 57, 0, 121], ["-", 8, 196, 0, 7, 8, 196, 0, 57, 0, 24], ["-", 8, 196, 0, 57, 15, 16, 31, 16, 31, 22], ["-", 8, 196, 0, 57, 15, 16, 31, 16, 17, 33], ["-", 15, 16, 31, 16, 12, 204, 205, 204, 205, 22...
8
591
using System; using System.Linq; class Program { static int N; static int Ma; static int Mb; static int[] a; static int[] b; static int[] c; static void Main() { /*入力を受け取る*/ int[] inputs = Console.ReadLine().Split().Select(int.Parse).ToArray(); N = inputs[0]; Ma = inputs[1]; Mb = inp...
using System; using System.Linq; class Program { static int N; static int Ma; static int Mb; static int[] a; static int[] b; static int[] c; static void Main() { /*入力を受け取る*/ int[] inputs = Console.ReadLine().Split().Select(int.Parse).ToArray(); N = inputs[0]; Ma = inputs[1]; Mb = inp...
[["-", 0, 246, 0, 248, 8, 196, 0, 116, 0, 117], ["+", 0, 1, 0, 11, 31, 204, 205, 204, 205, 22], ["+", 0, 11, 31, 204, 205, 204, 206, 207, 0, 70], ["+", 31, 204, 205, 204, 206, 207, 0, 28, 0, 22], ["+", 0, 11, 31, 204, 205, 204, 206, 207, 0, 73], ["+", 0, 1, 0, 11, 31, 204, 206, 207, 0, 70], ["+", 0, 11, 31, 204, 206, 2...
8
528
using System; using System.Linq; namespace abc054_d { class Program { static void Main(string[] args) { int[] x = Console.ReadLine().Split().Select(int.Parse).ToArray(); int[,] dp = new int[500, 500]; int inf = 100000000; for (int i = 0; i < 500; i++) { for (int j = 0; j < 500; j++) dp[...
using System; using System.Linq; namespace abc054_d { class Program { static void Main(string[] args) { int[] x = Console.ReadLine().Split().Select(int.Parse).ToArray(); int[,] dp = new int[500, 500]; int inf = 100000000; for (int i = 0; i < 500; i++) { for (int j = 0; j < 500; j++) dp[...
[["+", 0, 7, 10, 198, 0, 200, 0, 212, 0, 203], ["+", 8, 196, 0, 7, 8, 196, 0, 7, 0, 35], ["+", 0, 7, 8, 196, 0, 7, 15, 16, 31, 22], ["+", 0, 7, 8, 196, 0, 7, 15, 16, 17, 20], ["-", 8, 196, 0, 7, 8, 196, 0, 7, 0, 35], ["-", 0, 7, 8, 196, 0, 7, 15, 16, 31, 22], ["-", 0, 7, 8, 196, 0, 7, 15, 16, 17, 18], ["-", 0, 7, 8, 19...
8
320
using System; using System.Collections.Generic; using System.Linq; namespace ProgramingStudying2 { class Program { static void Main(string[] args) { var n = int.Parse(Console.ReadLine()); var a = Console.ReadLine().Split().Select(int.Parse).ToList(); var even = 0; for (int i = 0; i < n; i++) { ...
using System; using System.Collections.Generic; using System.Linq; namespace ProgramingStudying2 { class Program { static void Main(string[] args) { var n = int.Parse(Console.ReadLine()); var a = Console.ReadLine().Split().Select(int.Parse).ToList(); var even = 0; for (int i = 0; i < n; i++) { ...
[["-", 8, 201, 0, 195, 8, 196, 0, 57, 0, 121], ["-", 8, 201, 0, 195, 8, 196, 0, 57, 0, 24], ["-", 0, 57, 15, 16, 31, 16, 31, 23, 0, 24], ["-", 15, 16, 31, 16, 31, 23, 0, 16, 31, 22], ["-", 15, 16, 31, 16, 31, 23, 0, 16, 17, 72], ["-", 15, 16, 31, 16, 31, 23, 0, 16, 12, 22], ["-", 0, 57, 15, 16, 31, 16, 31, 23, 0, 25], ...
8
175
using System; using System.Collections.Generic; using System.IO; using System.Linq; using static System.Math; namespace Sample { public class Program { public static void Main(string[] args) { using (var sc = new SetConsole()) { Solve(); } } public static void Solve() { int n = GetString().ToInt(); ...
using System; using System.Collections.Generic; using System.IO; using System.Linq; using static System.Math; namespace Sample { public class Program { public static void Main(string[] args) { using (var sc = new SetConsole()) { Solve(); } } public static void Solve() { int n = GetString().ToInt(); ...
[["-", 0, 57, 15, 16, 31, 16, 31, 16, 31, 22], ["-", 0, 57, 15, 16, 31, 16, 31, 16, 17, 109], ["-", 0, 57, 15, 16, 31, 16, 31, 16, 12, 203], ["-", 8, 196, 0, 57, 15, 16, 31, 16, 17, 60], ["-", 8, 196, 0, 57, 15, 16, 31, 16, 12, 203], ["-", 0, 195, 8, 196, 0, 57, 15, 16, 17, 98], ["-", 8, 196, 0, 57, 15, 16, 12, 16, 17,...
8
800
using System; using System.Text; using System.Linq; using System.Collections.Generic; class Program { const long mod = 1000000007; // public static int[] max; static void Main(string[] args) { char[] cs = new char[] { ' ', ',' }; int val = int.Parse(Console.ReadLine()); int[] vals = parseAry(Conso...
using System; using System.Text; using System.Linq; using System.Collections.Generic; class Program { const long mod = 1000000007; // public static int[] max; static void Main(string[] args) { char[] cs = new char[] { ' ', ',' }; int val = int.Parse(Console.ReadLine()); int[] vals = parseAry(Conso...
[["-", 8, 196, 0, 57, 75, 196, 0, 57, 0, 121], ["-", 8, 196, 0, 57, 75, 196, 0, 57, 0, 24], ["-", 75, 196, 0, 57, 15, 16, 31, 23, 0, 24], ["-", 15, 16, 31, 23, 0, 16, 31, 23, 0, 24], ["-", 31, 23, 0, 16, 31, 23, 0, 16, 31, 22], ["-", 31, 23, 0, 16, 31, 23, 0, 16, 17, 72], ["-", 0, 16, 31, 23, 0, 16, 12, 23, 0, 24], ["-...
8
395
using System; using System.Collections; using System.Collections.Generic; using System.Linq; using System.Text; class TEST { static void Main() { Sol mySol = new Sol(); mySol.Solve(); } } class Sol { public void Solve() { long sum = 0; for (int i = 0; i < N; i++) sum += A[i]; long inc...
using System; using System.Collections; using System.Collections.Generic; using System.Linq; using System.Text; class TEST { static void Main() { Sol mySol = new Sol(); mySol.Solve(); } } class Sol { public void Solve() { long sum = 0; for (int i = 0; i < N; i++) sum += A[i]; long inc...
[["+", 8, 196, 0, 7, 8, 196, 0, 57, 0, 121], ["+", 8, 196, 0, 7, 8, 196, 0, 57, 0, 24], ["+", 8, 196, 0, 57, 15, 16, 31, 204, 205, 22], ["+", 0, 57, 15, 16, 31, 204, 206, 207, 0, 70], ["+", 15, 16, 31, 204, 206, 207, 0, 28, 0, 22], ["+", 0, 57, 15, 16, 31, 204, 206, 207, 0, 73], ["+", 0, 7, 8, 196, 0, 57, 15, 16, 17, 1...
8
566
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.IO; static class Program { const int mod = 1000000007; static List<int>[] li; static long[] h; static string ans = "YES"; static void Main() { Sc sc = new Sc(); int n = sc.I; h = sc.La2; li = new...
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.IO; static class Program { const int mod = 1000000007; static List<int>[] li; static long[] h; static string ans = "YES"; static void Main() { Sc sc = new Sc(); int n = sc.I; h = sc.La2; li = new...
[["-", 0, 57, 75, 57, 75, 57, 15, 16, 17, 106], ["-", 75, 57, 75, 57, 15, 16, 12, 16, 31, 22], ["-", 75, 57, 75, 57, 15, 16, 12, 16, 17, 60], ["-", 75, 57, 75, 57, 15, 16, 12, 16, 12, 203], ["+", 8, 196, 0, 57, 15, 16, 31, 16, 12, 22], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 17, 106], ["+", 8, 196, 0, 57, 15, 16, 12, 16, ...
8
669
using System; using System.IO; class Program { static void Main(string[] args) { var writer = new StreamWriter(Console.OpenStandardOutput()) { AutoFlush = false }; Console.SetOut(writer); Console.WriteLine(Solve()); Console.Out.Flush(); } static object Solve() { var s = Console.ReadL...
using System; using System.IO; class Program { static void Main(string[] args) { var writer = new StreamWriter(Console.OpenStandardOutput()) { AutoFlush = false }; Console.SetOut(writer); Console.WriteLine(Solve()); Console.Out.Flush(); } static object Solve() { var s = Console.ReadL...
[["-", 0, 197, 0, 198, 0, 200, 0, 212, 0, 203], ["+", 0, 198, 0, 200, 0, 212, 0, 241, 0, 33], ["+", 0, 198, 0, 200, 0, 212, 0, 241, 0, 203], ["-", 0, 7, 8, 196, 0, 57, 15, 16, 17, 79], ["+", 8, 196, 0, 57, 15, 16, 31, 16, 17, 60], ["+", 0, 7, 8, 196, 0, 57, 15, 16, 17, 98], ["+", 8, 196, 0, 57, 15, 16, 12, 16, 31, 22],...
8
178
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace ABC053 { class ProblemB { static void Main(string[] args) { var sw = new System.IO.StreamWriter( Console.OpenStandardOutput()) { AutoFlush = false }; Console.SetOut(sw); ...
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace ABC053 { class ProblemB { static void Main(string[] args) { var sw = new System.IO.StreamWriter( Console.OpenStandardOutput()) { AutoFlush = false }; Console.SetOut(sw); ...
[["-", 0, 197, 0, 198, 0, 200, 0, 212, 0, 203], ["+", 0, 197, 0, 198, 0, 200, 0, 212, 0, 203], ["+", 0, 7, 8, 196, 0, 57, 15, 16, 17, 67], ["+", 8, 196, 0, 57, 15, 16, 12, 16, 31, 22], ["+", 8, 196, 0, 57, 15, 16, 12, 16, 17, 18], ["+", 8, 196, 0, 57, 15, 16, 12, 16, 12, 22], ["+", 8, 196, 0, 57, 15, 16, 12, 16, 17, 47...
8
172
using System; class Program { static void Main(string[] args) { var S = Console.ReadLine(); var length = S.Substring(S.IndexOf('A'), S.LastIndexOf('Z')).Length; Console.WriteLine(length); } }
using System; class Program { static void Main(string[] args) { var S = Console.ReadLine(); var length = S.Substring(S.IndexOf('A'), S.LastIndexOf('Z') - S.IndexOf('A') + 1) .Length; Console.WriteLine(length); } }
[["+", 3, 4, 0, 28, 0, 16, 31, 16, 17, 33], ["+", 0, 16, 31, 16, 12, 213, 63, 214, 205, 22], ["+", 0, 16, 31, 16, 12, 213, 63, 214, 0, 131], ["+", 0, 16, 31, 16, 12, 213, 63, 214, 141, 22], ["+", 0, 16, 31, 16, 12, 213, 3, 4, 0, 24], ["+", 12, 213, 3, 4, 0, 28, 0, 252, 0, 104], ["+", 12, 213, 3, 4, 0, 28, 0, 252, 0, 25...
8
62
using System; namespace abc_053_b { class Program { static void Main(string[] args) { int a1 = 0; string a = Console.ReadLine(); for (int i = 0; i < a.Length; i++) { if (a.Substring(i, 1) == "A") { a1 = i - 1; break; } } for (int i = a.Length; i > 0; i--) { if (...
using System; namespace abc_053_b { class Program { static void Main(string[] args) { long a1 = -123232; string a = Console.ReadLine(); for (long i = 0; i < a.Length; i++) { if (a.Substring((int)i, 1) == "A") { a1 = i - 1; break; } } for (long i = a.Length; i > 0; i--)...
[["-", 0, 195, 8, 196, 0, 197, 0, 198, 39, 199], ["+", 0, 195, 8, 196, 0, 197, 0, 198, 39, 199], ["-", 0, 197, 0, 198, 0, 200, 0, 212, 0, 203], ["+", 0, 198, 0, 200, 0, 212, 0, 241, 0, 33], ["+", 0, 198, 0, 200, 0, 212, 0, 241, 0, 203], ["-", 0, 195, 8, 196, 0, 7, 10, 198, 39, 199], ["+", 0, 195, 8, 196, 0, 7, 10, 198,...
8
139
using System; using System.Collections.Generic; using System.Diagnostics; using System.Linq; namespace AtCoder.C { public class Program { public static void Main() { var r = GetResult(); Debug.WriteLine(r); Console.Write(r); } private static object GetResult() { var x = ReadLong(...
using System; using System.Collections.Generic; using System.Diagnostics; using System.Linq; namespace AtCoder.C { public class Program { public static void Main() { var r = GetResult(); Debug.WriteLine(r); Console.Write(r); } private static object GetResult() { var x = ReadLong(...
[["+", 0, 195, 8, 196, 0, 57, 15, 16, 17, 60], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 12, 203], ["+", 8, 201, 0, 195, 8, 196, 0, 57, 0, 25], ["+", 0, 195, 8, 196, 0, 57, 64, 37, 0, 38], ["+", 0, 195, 8, 196, 0, 57, 64, 37, 0, 22], ["+", 0, 195, 8, 196, 0, 57, 64, 37, 0, 35], ["+", 8, 201, 0, 195, 8, 196, 0, 57, 0, 121], ...
8
391
using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Text; using System.Threading.Tasks; namespace AtCoder { partial class Program { static long mod = 1000000007; static void Swap<T>(ref T a, ref T b) { T temp = a; a = b; b = temp; } static void Main() { ...
using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Text; using System.Threading.Tasks; namespace AtCoder { partial class Program { static long mod = 1000000007; static void Swap<T>(ref T a, ref T b) { T temp = a; a = b; b = temp; } static void Main() { ...
[["+", 0, 41, 15, 16, 31, 16, 31, 23, 0, 24], ["+", 15, 16, 31, 16, 31, 23, 0, 16, 17, 33], ["+", 15, 16, 31, 16, 31, 23, 0, 16, 12, 203], ["+", 0, 41, 15, 16, 31, 16, 31, 23, 0, 25], ["-", 0, 200, 0, 212, 0, 41, 15, 16, 12, 203], ["+", 0, 200, 0, 212, 0, 41, 15, 16, 12, 203], ["+", 64, 16, 31, 16, 31, 16, 31, 23, 0, 2...
8
1,164
using System; using System.Collections; using System.Collections.Generic; using System.Linq; using System.Text; using Console = System.Console; namespace Atcoder { class Program { static void Main(string[] args) { long r = ReadLong(); var ret = r / 11; if (r <= 6) { Console.WriteLine(1); retu...
using System; using System.Collections; using System.Collections.Generic; using System.Linq; using System.Text; using Console = System.Console; namespace Atcoder { class Program { static void Main(string[] args) { long r = ReadLong(); var ret = r / 11; if (r <= 6) { Console.WriteLine(1); retu...
[["+", 8, 196, 0, 57, 64, 196, 0, 37, 0, 38], ["+", 8, 196, 0, 57, 64, 196, 0, 37, 0, 35], ["-", 8, 201, 0, 195, 8, 196, 0, 57, 0, 95], ["+", 8, 201, 0, 195, 8, 196, 0, 57, 0, 121], ["+", 8, 201, 0, 195, 8, 196, 0, 57, 0, 24], ["+", 8, 196, 0, 57, 15, 16, 31, 16, 31, 22], ["+", 8, 196, 0, 57, 15, 16, 31, 16, 17, 109], ...
8
309
using System; using System.Collections.Generic; using System.Linq; using System.Text.RegularExpressions; namespace kyoupuro { class MainClass { public static void Main() { var x = Input.NextLong(); Console.WriteLine((x / 11) * 2 + Convert.ToInt64(x % 11 > 6) + 1L); } } class Input { static IEnumerato...
using System; using System.Collections.Generic; using System.Linq; using System.Text.RegularExpressions; namespace kyoupuro { class MainClass { public static void Main() { var x = Input.NextLong(); Console.WriteLine(((x - 1) / 11 + 1) * 2 - Convert.ToInt64(x % 11 <= 6 && x % 11 > 0))...
[["+", 31, 23, 0, 16, 31, 16, 31, 23, 0, 24], ["+", 0, 16, 31, 16, 31, 23, 0, 16, 17, 33], ["+", 0, 16, 31, 16, 31, 23, 0, 16, 12, 203], ["+", 31, 23, 0, 16, 31, 16, 31, 23, 0, 25], ["+", 0, 16, 31, 16, 31, 23, 0, 16, 17, 72], ["-", 3, 4, 0, 28, 0, 16, 31, 16, 17, 72], ["+", 0, 213, 3, 4, 0, 28, 0, 16, 17, 33], ["-", 1...
8
333
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.IO; using System.Diagnostics; class Myon { public Myon() {} public static int Main() { new Myon().calc(); return 0; } Scanner cin; Func cin2; void calc() { cin = new...
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.IO; using System.Diagnostics; class Myon { public Myon() {} public static int Main() { new Myon().calc(); return 0; } Scanner cin; Func cin2; void calc() { cin = new...
[["-", 0, 195, 8, 196, 0, 57, 15, 16, 12, 203], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 12, 203], ["-", 75, 196, 0, 1, 0, 11, 0, 202, 0, 107], ["+", 75, 196, 0, 1, 0, 11, 0, 202, 0, 32], ["-", 0, 57, 75, 196, 0, 57, 15, 16, 12, 203], ["+", 75, 196, 0, 57, 15, 16, 31, 16, 12, 203], ["+", 0, 57, 75, 196, 0, 57, 15, 16, 17, ...
8
741
using System; using System.Linq; using System.Collections.Generic; namespace Algorithm { class Program { static void Main(string[] args) { var x = long.Parse(Console.ReadLine()); var ope = 0L; if (x >= 11) { var tmp = x % 11; ope = (x / 11) * 2; if (tmp > 6) ope += 2; els...
using System; using System.Linq; using System.Collections.Generic; namespace Algorithm { class Program { static void Main(string[] args) { var x = long.Parse(Console.ReadLine()); var ope = 0L; if (x >= 11) { var tmp = x % 11; ope = (x / 11) * 2; if (tmp == 0) ope--; if (t...
[["+", 0, 57, 64, 196, 0, 57, 15, 16, 17, 60], ["+", 0, 57, 64, 196, 0, 57, 15, 16, 12, 203], ["+", 8, 196, 0, 57, 64, 196, 0, 57, 0, 25], ["+", 64, 196, 0, 57, 64, 1, 0, 223, 0, 22], ["+", 64, 196, 0, 57, 64, 1, 0, 223, 0, 68], ["+", 0, 57, 64, 196, 0, 57, 64, 1, 0, 35], ["+", 8, 196, 0, 57, 64, 196, 0, 57, 0, 121], [...
8
118
using System; using System.Linq; using System.Collections.Generic; using static System.Console; class Program { static void Main(string[] args) { solve(); } static Scanner cin; static long x; static void input() { cin = new Scanner(); x = cin.nextLong(); } static void solve() { input(); lo...
using System; using System.Linq; using System.Collections.Generic; using static System.Console; class Program { static void Main(string[] args) { solve(); } static Scanner cin; static long x; static void input() { cin = new Scanner(); x = cin.nextLong(); } static void solve() { input(); lo...
[["+", 0, 1, 0, 11, 12, 41, 15, 16, 17, 60], ["+", 0, 1, 0, 11, 12, 41, 15, 16, 12, 203], ["+", 8, 196, 0, 1, 0, 11, 12, 41, 0, 101], ["+", 8, 196, 0, 1, 0, 11, 12, 41, 64, 203], ["+", 8, 196, 0, 1, 0, 11, 12, 41, 0, 102], ["+", 12, 41, 75, 41, 15, 16, 31, 16, 31, 22], ["+", 12, 41, 75, 41, 15, 16, 31, 16, 17, 109], ["...
8
457
using System; using System.Text; using System.Collections.Generic; using System.ComponentModel; using System.Linq; using System.Threading.Tasks; class Program { const int mod = 1000000007; static void Main(string[] args) { long ans = 0; long x = long.Parse(Console.ReadLine()); ans += (x / 11) * 2; ...
using System; using System.Text; using System.Collections.Generic; using System.ComponentModel; using System.Linq; using System.Threading.Tasks; class Program { const int mod = 1000000007; static void Main(string[] args) { long ans = 0; long x = long.Parse(Console.ReadLine()); ans += (x / 11) * 2; ...
[["+", 0, 195, 8, 196, 0, 57, 15, 16, 17, 79], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 12, 203], ["+", 8, 201, 0, 195, 8, 196, 0, 57, 0, 25], ["+", 0, 195, 8, 196, 0, 57, 64, 196, 0, 45], ["+", 8, 196, 0, 57, 64, 196, 0, 57, 0, 121], ["+", 8, 196, 0, 57, 64, 196, 0, 57, 0, 24], ["+", 64, 196, 0, 57, 15, 16, 31, 16, 31, 22...
8
109
using System; namespace ConsoleApp1 { class Program { static void Main(string[] args) { new Program().Sol(); } public void Sol() { long x = long.Parse(Console.ReadLine()); long a = x / 11; long ans = a * 2; long b = x % 11; if (b > 6) { ans += 2; } else { ans += 1; } ...
using System; namespace ConsoleApp1 { class Program { static void Main(string[] args) { new Program().Sol(); } public void Sol() { long x = long.Parse(Console.ReadLine()); long a = x / 11; long ans = a * 2; long b = x % 11; if (b == 0) { } else if (b > 6) { ans += 2; } else { ...
[["+", 0, 195, 8, 196, 0, 57, 15, 16, 17, 60], ["+", 0, 195, 8, 196, 0, 57, 15, 16, 12, 203], ["+", 8, 201, 0, 195, 8, 196, 0, 57, 0, 25], ["+", 0, 195, 8, 196, 0, 57, 64, 196, 0, 45], ["+", 0, 195, 8, 196, 0, 57, 64, 196, 0, 46], ["+", 8, 201, 0, 195, 8, 196, 0, 57, 0, 95], ["+", 0, 195, 8, 196, 0, 57, 75, 57, 0, 121]...
8
99