id
int64
0
100M
language
stringclasses
3 values
prog_lang
stringclasses
6 values
category
stringclasses
10 values
difficulty
stringclasses
3 values
instruction
stringlengths
30
86
output
stringlengths
7
192
text
stringlengths
92
300
40,644,283
ru
C#
logic_ops
intermediate
Напишите на C# функцию, определяющую, является ли число 180 простым.
public bool IsPrime() { int n = 180; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
### Instruction: Напишите на C# функцию, определяющую, является ли число 180 простым. ### Response: public bool IsPrime() { int n = 180; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
12,587,307
en
Java
logic_ops
advanced
Write logic to check if the year 2093 is a leap year in Java.
public bool IsLeap() { int y = 2093; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
### Instruction: Write logic to check if the year 2093 is a leap year in Java. ### Response: public bool IsLeap() { int y = 2093; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
76,938,691
kk
Python
string_ops
advanced
Python тилінде мәтіндегі дауысты әріптердің санын есептейтін функцияны жазыңыз.
def count_vowels(s): return sum(1 for c in s if c in 'aeiouAEIOUаеёиоуыэюя')
### Instruction: Python тилінде мәтіндегі дауысты әріптердің санын есептейтін функцияны жазыңыз. ### Response: def count_vowels(s): return sum(1 for c in s if c in 'aeiouAEIOUаеёиоуыэюя')
36,004,332
ru
C#
logic_ops
advanced
Напишите на C# функцию, определяющую, является ли число 424 простым.
public bool IsPrime() { int n = 424; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
### Instruction: Напишите на C# функцию, определяющую, является ли число 424 простым. ### Response: public bool IsPrime() { int n = 424; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
60,071,353
ru
C#
array_ops
intermediate
Напишите на C# функцию, которая фильтрует только четные числа из списка.
public System.Collections.Generic.List<int> Filter(int[] arr) { var res = new System.Collections.Generic.List<int>(); foreach(int x in arr) if(x % 2 == 0) res.Add(x); return res; }
### Instruction: Напишите на C# функцию, которая фильтрует только четные числа из списка. ### Response: public System.Collections.Generic.List<int> Filter(int[] arr) { var res = new System.Collections.Generic.List<int>(); foreach(int x in arr) if(x % 2 == 0) res.Add(x); return res; }
50,503,178
ru
Unity
logic_ops
advanced
Напишите на Unity функцию, определяющую, является ли число 254 простым.
public bool IsPrime() { int n = 254; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
### Instruction: Напишите на Unity функцию, определяющую, является ли число 254 простым. ### Response: public bool IsPrime() { int n = 254; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
54,228,590
ru
JavaScript
array_ops
advanced
Напишите на JavaScript функцию, которая разворачивает список задом наперед.
const reverseArr = arr => arr.reverse();
### Instruction: Напишите на JavaScript функцию, которая разворачивает список задом наперед. ### Response: const reverseArr = arr => arr.reverse();
50,880,505
kk
C++
logic_ops
advanced
C++ тилінде 1969 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
public bool IsLeap() { int y = 1969; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
### Instruction: C++ тилінде 1969 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. ### Response: public bool IsLeap() { int y = 1969; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
72,933,353
ru
Python
logic_ops
advanced
Напишите на Python логику проверки, является ли год 1905 високосным.
def is_leap(): year = 1905 return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0)
### Instruction: Напишите на Python логику проверки, является ли год 1905 високосным. ### Response: def is_leap(): year = 1905 return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0)
1,041,007
en
Unity
var_decl
beginner
How to declare a variable health with value 366678 in Unity?
int health = 366678;
### Instruction: How to declare a variable health with value 366678 in Unity? ### Response: int health = 366678;
547,046
ru
Python
factorial
advanced
Напиши функцию на Python, которая вычисляет факториал числа 368.
def factorial(n): return 1 if n <= 1 else n * factorial(n - 1) print(factorial(368))
### Instruction: Напиши функцию на Python, которая вычисляет факториал числа 368. ### Response: def factorial(n): return 1 if n <= 1 else n * factorial(n - 1) print(factorial(368))
43,103,595
ru
Java
logic_ops
intermediate
Напишите на Java функцию, определяющую, является ли число 327 простым.
public bool IsPrime() { int n = 327; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
### Instruction: Напишите на Java функцию, определяющую, является ли число 327 простым. ### Response: public bool IsPrime() { int n = 327; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
48,200,232
ru
C#
string_ops
advanced
Напишите на C# функцию, которая переводит строку в верхний регистр.
public string ToUpper(string s) { return s.ToUpper(); }
### Instruction: Напишите на C# функцию, которая переводит строку в верхний регистр. ### Response: public string ToUpper(string s) { return s.ToUpper(); }
4,245,736
en
Java
var_decl
beginner
How to declare a variable speed with value 433744 in Java?
int speed = 433744;
### Instruction: How to declare a variable speed with value 433744 in Java? ### Response: int speed = 433744;
13,001,468
en
JavaScript
string_ops
intermediate
Write a function that converts a string to uppercase in JavaScript.
const toUpper = s => s.toUpperCase();
### Instruction: Write a function that converts a string to uppercase in JavaScript. ### Response: const toUpper = s => s.toUpperCase();
2,368,884
ru
JavaScript
var_decl
beginner
Как объявить переменную offset со значением 743183 в JavaScript?
let offset = 743183;
### Instruction: Как объявить переменную offset со значением 743183 в JavaScript? ### Response: let offset = 743183;
1,888,035
ru
Java
var_decl
beginner
Как объявить переменную total со значением 792701 в Java?
int total = 792701;
### Instruction: Как объявить переменную total со значением 792701 в Java? ### Response: int total = 792701;
658,810
kk
Unity
var_decl
beginner
Unity тілінде 507439 мәнімен level айнымалысын қалай жариялауға болады?
int level = 507439;
### Instruction: Unity тілінде 507439 мәнімен level айнымалысын қалай жариялауға болады? ### Response: int level = 507439;
2,887,167
en
C#
var_decl
beginner
How to declare a variable count with value 185037 in C#?
int count = 185037;
### Instruction: How to declare a variable count with value 185037 in C#? ### Response: int count = 185037;
30,233,751
kk
C#
logic_ops
advanced
C# тилінде 224 санының жай сан екенін анықтайтын функцияны жазыңыз.
public bool IsPrime() { int n = 224; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
### Instruction: C# тилінде 224 санының жай сан екенін анықтайтын функцияны жазыңыз. ### Response: public bool IsPrime() { int n = 224; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
4,565,314
en
C#
var_decl
beginner
How to declare a variable limit with value 48051 in C#?
int limit = 48051;
### Instruction: How to declare a variable limit with value 48051 in C#? ### Response: int limit = 48051;
4,672,060
kk
C#
var_decl
beginner
C# тілінде 78287 мәнімен level айнымалысын қалай жариялауға болады?
int level = 78287;
### Instruction: C# тілінде 78287 мәнімен level айнымалысын қалай жариялауға болады? ### Response: int level = 78287;
17,927,765
ru
JavaScript
array_ops
advanced
Напишите на JavaScript функцию, которая разворачивает список задом наперед.
const reverseArr = arr => arr.reverse();
### Instruction: Напишите на JavaScript функцию, которая разворачивает список задом наперед. ### Response: const reverseArr = arr => arr.reverse();
113,151
kk
JavaScript
factorial
advanced
JavaScript тілінде 4203 санының факториалын есептейтін функция жаз.
function factorial(n) { return n <= 1 ? 1 : n * factorial(n - 1); } console.log(factorial(4203));
### Instruction: JavaScript тілінде 4203 санының факториалын есептейтін функция жаз. ### Response: function factorial(n) { return n <= 1 ? 1 : n * factorial(n - 1); } console.log(factorial(4203));
10,461,558
en
Unity
string_ops
intermediate
Write a function that checks if a string is a palindrome in Unity.
public bool IsPalindrome(string s) { int min = 0, max = s.Length - 1; while (min < max) { if (s[min] != s[max]) return false; min++; max--; } return true; }
### Instruction: Write a function that checks if a string is a palindrome in Unity. ### Response: public bool IsPalindrome(string s) { int min = 0, max = s.Length - 1; while (min < max) { if (s[min] != s[max]) return false; min++; max--; } return true; }
97,329
kk
C#
var_decl
beginner
C# тілінде 176158 мәнімен score айнымалысын қалай жариялауға болады?
int score = 176158;
### Instruction: C# тілінде 176158 мәнімен score айнымалысын қалай жариялауға болады? ### Response: int score = 176158;
82,148,860
kk
Unity
logic_ops
intermediate
Unity тилінде 1971 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
public bool IsLeap() { int y = 1971; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
### Instruction: Unity тилінде 1971 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. ### Response: public bool IsLeap() { int y = 1971; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
3,665,210
kk
C++
var_decl
beginner
C++ тілінде 290632 мәнімен health айнымалысын қалай жариялауға болады?
int health = 290632;
### Instruction: C++ тілінде 290632 мәнімен health айнымалысын қалай жариялауға болады? ### Response: int health = 290632;
25,241,845
ru
JavaScript
string_ops
intermediate
Напишите на JavaScript функцию, которая переводит строку в верхний регистр.
const toUpper = s => s.toUpperCase();
### Instruction: Напишите на JavaScript функцию, которая переводит строку в верхний регистр. ### Response: const toUpper = s => s.toUpperCase();
76,489,673
kk
Unity
array_ops
advanced
Unity тилінде тізімді керісінше айналдыратын функцияны жазыңыз.
public void Reverse(int[] arr) { System.Array.Reverse(arr); }
### Instruction: Unity тилінде тізімді керісінше айналдыратын функцияны жазыңыз. ### Response: public void Reverse(int[] arr) { System.Array.Reverse(arr); }
215,543
ru
Python
factorial
advanced
Напиши функцию на Python, которая вычисляет факториал числа 3909.
def factorial(n): return 1 if n <= 1 else n * factorial(n - 1) print(factorial(3909))
### Instruction: Напиши функцию на Python, которая вычисляет факториал числа 3909. ### Response: def factorial(n): return 1 if n <= 1 else n * factorial(n - 1) print(factorial(3909))
49,118,576
en
Unity
string_ops
intermediate
Write a function that counts vowels in a text in Unity.
public int CountVowels(string s) { int c = 0; foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++; return c; }
### Instruction: Write a function that counts vowels in a text in Unity. ### Response: public int CountVowels(string s) { int c = 0; foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++; return c; }
56,839,516
en
C++
string_ops
intermediate
Write a function that counts vowels in a text in C++.
public int CountVowels(string s) { int c = 0; foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++; return c; }
### Instruction: Write a function that counts vowels in a text in C++. ### Response: public int CountVowels(string s) { int c = 0; foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++; return c; }
47,481,314
ru
Java
logic_ops
advanced
Напишите на Java логику проверки, является ли год 2065 високосным.
public bool IsLeap() { int y = 2065; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
### Instruction: Напишите на Java логику проверки, является ли год 2065 високосным. ### Response: public bool IsLeap() { int y = 2065; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
10,819,179
en
C++
string_ops
intermediate
Write a function that counts vowels in a text in C++.
public int CountVowels(string s) { int c = 0; foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++; return c; }
### Instruction: Write a function that counts vowels in a text in C++. ### Response: public int CountVowels(string s) { int c = 0; foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++; return c; }
20,424,819
kk
JavaScript
logic_ops
advanced
JavaScript тилінде 2024 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
function isLeap() { let y = 2024; return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0); }
### Instruction: JavaScript тилінде 2024 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. ### Response: function isLeap() { let y = 2024; return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0); }
33,289,680
ru
JavaScript
logic_ops
intermediate
Напишите на JavaScript функцию, определяющую, является ли число 305 простым.
function isPrime() { let n = 305; if (n <= 1) return false; for (let i = 2; i * i <= n; i++) if (n % i === 0) return false; return true; }
### Instruction: Напишите на JavaScript функцию, определяющую, является ли число 305 простым. ### Response: function isPrime() { let n = 305; if (n <= 1) return false; for (let i = 2; i * i <= n; i++) if (n % i === 0) return false; return true; }
99,860,373
ru
Python
string_ops
intermediate
Напишите на Python функцию, которая проверяет, является ли строка палиндромом.
def is_palindrome(s): return s == s[::-1]
### Instruction: Напишите на Python функцию, которая проверяет, является ли строка палиндромом. ### Response: def is_palindrome(s): return s == s[::-1]
95,009,701
kk
Java
logic_ops
advanced
Java тилінде 124 санының жай сан екенін анықтайтын функцияны жазыңыз.
public bool IsPrime() { int n = 124; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
### Instruction: Java тилінде 124 санының жай сан екенін анықтайтын функцияны жазыңыз. ### Response: public bool IsPrime() { int n = 124; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
31,231,620
ru
Python
string_ops
intermediate
Напишите на Python функцию, которая проверяет, является ли строка палиндромом.
def is_palindrome(s): return s == s[::-1]
### Instruction: Напишите на Python функцию, которая проверяет, является ли строка палиндромом. ### Response: def is_palindrome(s): return s == s[::-1]
1,019,152
kk
C++
var_decl
beginner
C++ тілінде 450647 мәнімен result айнымалысын қалай жариялауға болады?
int result = 450647;
### Instruction: C++ тілінде 450647 мәнімен result айнымалысын қалай жариялауға болады? ### Response: int result = 450647;
19,433,485
ru
C++
string_ops
intermediate
Напишите на C++ функцию, которая проверяет, является ли строка палиндромом.
public bool IsPalindrome(string s) { int min = 0, max = s.Length - 1; while (min < max) { if (s[min] != s[max]) return false; min++; max--; } return true; }
### Instruction: Напишите на C++ функцию, которая проверяет, является ли строка палиндромом. ### Response: public bool IsPalindrome(string s) { int min = 0, max = s.Length - 1; while (min < max) { if (s[min] != s[max]) return false; min++; max--; } return true; }
2,855,157
kk
Python
var_decl
beginner
Python тілінде 505113 мәнімен size айнымалысын қалай жариялауға болады?
size = 505113
### Instruction: Python тілінде 505113 мәнімен size айнымалысын қалай жариялауға болады? ### Response: size = 505113
3,393,756
en
C#
var_decl
beginner
How to declare a variable weight with value 74190 in C#?
int weight = 74190;
### Instruction: How to declare a variable weight with value 74190 in C#? ### Response: int weight = 74190;
12,833,302
ru
JavaScript
string_ops
intermediate
Напишите на JavaScript функцию, которая считает количество гласных букв в тексте.
const countVowels = s => (s.match(/[aeiou]/gi) || []).length;
### Instruction: Напишите на JavaScript функцию, которая считает количество гласных букв в тексте. ### Response: const countVowels = s => (s.match(/[aeiou]/gi) || []).length;
45,455,573
en
Unity
array_ops
advanced
Write a function that finds the maximum number in an array in Unity.
public int GetMax(int[] arr) { int max = arr[0]; foreach(int x in arr) if(x > max) max = x; return max; }
### Instruction: Write a function that finds the maximum number in an array in Unity. ### Response: public int GetMax(int[] arr) { int max = arr[0]; foreach(int x in arr) if(x > max) max = x; return max; }
34,064,265
kk
C#
array_ops
intermediate
C# тилінде тізімді керісінше айналдыратын функцияны жазыңыз.
public void Reverse(int[] arr) { System.Array.Reverse(arr); }
### Instruction: C# тилінде тізімді керісінше айналдыратын функцияны жазыңыз. ### Response: public void Reverse(int[] arr) { System.Array.Reverse(arr); }
84,504,522
ru
JavaScript
logic_ops
advanced
Напишите на JavaScript функцию, определяющую, является ли число 171 простым.
function isPrime() { let n = 171; if (n <= 1) return false; for (let i = 2; i * i <= n; i++) if (n % i === 0) return false; return true; }
### Instruction: Напишите на JavaScript функцию, определяющую, является ли число 171 простым. ### Response: function isPrime() { let n = 171; if (n <= 1) return false; for (let i = 2; i * i <= n; i++) if (n % i === 0) return false; return true; }
80,816,839
ru
JavaScript
array_ops
intermediate
Напишите на JavaScript функцию, которая фильтрует только четные числа из списка.
const filterEven = arr => arr.filter(x => x % 2 === 0);
### Instruction: Напишите на JavaScript функцию, которая фильтрует только четные числа из списка. ### Response: const filterEven = arr => arr.filter(x => x % 2 === 0);
72,112,533
kk
Unity
string_ops
advanced
Unity тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз.
public string ToUpper(string s) { return s.ToUpper(); }
### Instruction: Unity тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз. ### Response: public string ToUpper(string s) { return s.ToUpper(); }
835,350
kk
C++
var_decl
beginner
C++ тілінде 336665 мәнімен speed айнымалысын қалай жариялауға болады?
int speed = 336665;
### Instruction: C++ тілінде 336665 мәнімен speed айнымалысын қалай жариялауға болады? ### Response: int speed = 336665;
1,869,576
ru
Python
var_decl
beginner
Как объявить переменную total со значением 231841 в Python?
total = 231841
### Instruction: Как объявить переменную total со значением 231841 в Python? ### Response: total = 231841
12,390,740
ru
C#
string_ops
advanced
Напишите на C# функцию, которая считает количество гласных букв в тексте.
public int CountVowels(string s) { int c = 0; foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++; return c; }
### Instruction: Напишите на C# функцию, которая считает количество гласных букв в тексте. ### Response: public int CountVowels(string s) { int c = 0; foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++; return c; }
1,228,117
kk
Unity
var_decl
beginner
Unity тілінде 589313 мәнімен result айнымалысын қалай жариялауға болады?
int result = 589313;
### Instruction: Unity тілінде 589313 мәнімен result айнымалысын қалай жариялауға болады? ### Response: int result = 589313;
1,186,185
kk
Unity
var_decl
beginner
Unity тілінде 352094 мәнімен value айнымалысын қалай жариялауға болады?
int value = 352094;
### Instruction: Unity тілінде 352094 мәнімен value айнымалысын қалай жариялауға болады? ### Response: int value = 352094;
55,406,143
ru
C#
array_ops
advanced
Напишите на C# функцию, которая фильтрует только четные числа из списка.
public System.Collections.Generic.List<int> Filter(int[] arr) { var res = new System.Collections.Generic.List<int>(); foreach(int x in arr) if(x % 2 == 0) res.Add(x); return res; }
### Instruction: Напишите на C# функцию, которая фильтрует только четные числа из списка. ### Response: public System.Collections.Generic.List<int> Filter(int[] arr) { var res = new System.Collections.Generic.List<int>(); foreach(int x in arr) if(x % 2 == 0) res.Add(x); return res; }
36,082,523
ru
C++
logic_ops
advanced
Напишите на C++ логику проверки, является ли год 2073 високосным.
public bool IsLeap() { int y = 2073; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
### Instruction: Напишите на C++ логику проверки, является ли год 2073 високосным. ### Response: public bool IsLeap() { int y = 2073; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
20,364,887
ru
C#
string_ops
advanced
Напишите на C# функцию, которая считает количество гласных букв в тексте.
public int CountVowels(string s) { int c = 0; foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++; return c; }
### Instruction: Напишите на C# функцию, которая считает количество гласных букв в тексте. ### Response: public int CountVowels(string s) { int c = 0; foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++; return c; }
3,178,545
en
C++
var_decl
beginner
How to declare a variable buffer with value 278824 in C++?
int buffer = 278824;
### Instruction: How to declare a variable buffer with value 278824 in C++? ### Response: int buffer = 278824;
2,049,507
en
Unity
var_decl
beginner
How to declare a variable size with value 979284 in Unity?
int size = 979284;
### Instruction: How to declare a variable size with value 979284 in Unity? ### Response: int size = 979284;
1,962,756
en
C++
var_decl
beginner
How to declare a variable count with value 412678 in C++?
int count = 412678;
### Instruction: How to declare a variable count with value 412678 in C++? ### Response: int count = 412678;
3,081,890
kk
JavaScript
var_decl
beginner
JavaScript тілінде 195689 мәнімен buffer айнымалысын қалай жариялауға болады?
let buffer = 195689;
### Instruction: JavaScript тілінде 195689 мәнімен buffer айнымалысын қалай жариялауға болады? ### Response: let buffer = 195689;
38,413,917
kk
Python
logic_ops
intermediate
Python тилінде 2052 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
def is_leap(): year = 2052 return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0)
### Instruction: Python тилінде 2052 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. ### Response: def is_leap(): year = 2052 return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0)
54,108,087
kk
Java
string_ops
intermediate
Java тилінде жолдың палиндром екенін тексеретін функцияны жазыңыз.
public bool IsPalindrome(string s) { int min = 0, max = s.Length - 1; while (min < max) { if (s[min] != s[max]) return false; min++; max--; } return true; }
### Instruction: Java тилінде жолдың палиндром екенін тексеретін функцияны жазыңыз. ### Response: public bool IsPalindrome(string s) { int min = 0, max = s.Length - 1; while (min < max) { if (s[min] != s[max]) return false; min++; max--; } return true; }
533,250
ru
C++
var_decl
beginner
Как объявить переменную amount со значением 434000 в C++?
int amount = 434000;
### Instruction: Как объявить переменную amount со значением 434000 в C++? ### Response: int amount = 434000;
968,773
en
Java
sum_n
intermediate
Write a function in Java that sums numbers from 1 to 6156.
static int sumToN(int n) { int s = 0; for (int i = 1; i <= n; i++) s += i; return s; } System.out.println(sumToN(6156));
### Instruction: Write a function in Java that sums numbers from 1 to 6156. ### Response: static int sumToN(int n) { int s = 0; for (int i = 1; i <= n; i++) s += i; return s; } System.out.println(sumToN(6156));
4,491,955
en
JavaScript
var_decl
beginner
How to declare a variable result with value 256569 in JavaScript?
let result = 256569;
### Instruction: How to declare a variable result with value 256569 in JavaScript? ### Response: let result = 256569;
65,625,158
ru
Java
array_ops
intermediate
Напишите на Java функцию, которая находит максимальное число в массиве.
public int GetMax(int[] arr) { int max = arr[0]; foreach(int x in arr) if(x > max) max = x; return max; }
### Instruction: Напишите на Java функцию, которая находит максимальное число в массиве. ### Response: public int GetMax(int[] arr) { int max = arr[0]; foreach(int x in arr) if(x > max) max = x; return max; }
1,493,045
ru
Python
var_decl
beginner
Как объявить переменную count со значением 648488 в Python?
count = 648488
### Instruction: Как объявить переменную count со значением 648488 в Python? ### Response: count = 648488
84,073,589
en
Unity
string_ops
intermediate
Write a function that checks if a string is a palindrome in Unity.
public bool IsPalindrome(string s) { int min = 0, max = s.Length - 1; while (min < max) { if (s[min] != s[max]) return false; min++; max--; } return true; }
### Instruction: Write a function that checks if a string is a palindrome in Unity. ### Response: public bool IsPalindrome(string s) { int min = 0, max = s.Length - 1; while (min < max) { if (s[min] != s[max]) return false; min++; max--; } return true; }
2,505,816
en
Unity
var_decl
beginner
How to declare a variable rate with value 281722 in Unity?
int rate = 281722;
### Instruction: How to declare a variable rate with value 281722 in Unity? ### Response: int rate = 281722;
92,482,093
ru
JavaScript
logic_ops
intermediate
Напишите на JavaScript логику проверки, является ли год 2007 високосным.
function isLeap() { let y = 2007; return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0); }
### Instruction: Напишите на JavaScript логику проверки, является ли год 2007 високосным. ### Response: function isLeap() { let y = 2007; return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0); }
1,760,916
en
Python
var_decl
beginner
How to declare a variable data with value 69835 in Python?
data = 69835
### Instruction: How to declare a variable data with value 69835 in Python? ### Response: data = 69835
973,875
en
Unity
var_decl
beginner
How to declare a variable result with value 339934 in Unity?
int result = 339934;
### Instruction: How to declare a variable result with value 339934 in Unity? ### Response: int result = 339934;
13,821,309
kk
JavaScript
array_ops
advanced
JavaScript тилінде жиымдағы ең үлкен санды табатын функцияны жазыңыз.
const getMax = arr => Math.max(...arr);
### Instruction: JavaScript тилінде жиымдағы ең үлкен санды табатын функцияны жазыңыз. ### Response: const getMax = arr => Math.max(...arr);
69,839,572
en
C++
string_ops
intermediate
Write a function that converts a string to uppercase in C++.
public string ToUpper(string s) { return s.ToUpper(); }
### Instruction: Write a function that converts a string to uppercase in C++. ### Response: public string ToUpper(string s) { return s.ToUpper(); }
41,951,172
ru
Java
logic_ops
intermediate
Напишите на Java логику проверки, является ли год 1907 високосным.
public bool IsLeap() { int y = 1907; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
### Instruction: Напишите на Java логику проверки, является ли год 1907 високосным. ### Response: public bool IsLeap() { int y = 1907; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
1,172,869
ru
JavaScript
var_decl
beginner
Как объявить переменную limit со значением 305224 в JavaScript?
let limit = 305224;
### Instruction: Как объявить переменную limit со значением 305224 в JavaScript? ### Response: let limit = 305224;
82,401,718
kk
C#
array_ops
advanced
C# тилінде тізімнен тек жұп сандарды сүзетін функцияны жазыңыз.
public System.Collections.Generic.List<int> Filter(int[] arr) { var res = new System.Collections.Generic.List<int>(); foreach(int x in arr) if(x % 2 == 0) res.Add(x); return res; }
### Instruction: C# тилінде тізімнен тек жұп сандарды сүзетін функцияны жазыңыз. ### Response: public System.Collections.Generic.List<int> Filter(int[] arr) { var res = new System.Collections.Generic.List<int>(); foreach(int x in arr) if(x % 2 == 0) res.Add(x); return res; }
33,909,790
en
Java
array_ops
advanced
Write a function that reverses a list in Java.
public void Reverse(int[] arr) { System.Array.Reverse(arr); }
### Instruction: Write a function that reverses a list in Java. ### Response: public void Reverse(int[] arr) { System.Array.Reverse(arr); }
13,355,345
en
Unity
string_ops
intermediate
Write a function that converts a string to uppercase in Unity.
public string ToUpper(string s) { return s.ToUpper(); }
### Instruction: Write a function that converts a string to uppercase in Unity. ### Response: public string ToUpper(string s) { return s.ToUpper(); }
34,770,930
kk
C#
array_ops
advanced
C# тилінде тізімнен тек жұп сандарды сүзетін функцияны жазыңыз.
public System.Collections.Generic.List<int> Filter(int[] arr) { var res = new System.Collections.Generic.List<int>(); foreach(int x in arr) if(x % 2 == 0) res.Add(x); return res; }
### Instruction: C# тилінде тізімнен тек жұп сандарды сүзетін функцияны жазыңыз. ### Response: public System.Collections.Generic.List<int> Filter(int[] arr) { var res = new System.Collections.Generic.List<int>(); foreach(int x in arr) if(x % 2 == 0) res.Add(x); return res; }
158,962
kk
C#
sum_n
intermediate
C# тілінде 1-ден 8603-ге дейінгі сандардың қосындысын есептейтін функция жаз.
static int SumToN(int n) { int s = 0; for (int i = 1; i <= n; i++) s += i; return s; } Console.WriteLine(SumToN(8603));
### Instruction: C# тілінде 1-ден 8603-ге дейінгі сандардың қосындысын есептейтін функция жаз. ### Response: static int SumToN(int n) { int s = 0; for (int i = 1; i <= n; i++) s += i; return s; } Console.WriteLine(SumToN(8603));
10,886,694
kk
JavaScript
string_ops
intermediate
JavaScript тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз.
const toUpper = s => s.toUpperCase();
### Instruction: JavaScript тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз. ### Response: const toUpper = s => s.toUpperCase();
721,512
en
C#
factorial
advanced
Write a function in C# that calculates the factorial of 2544.
static long Factorial(int n) { return n <= 1 ? 1 : n * Factorial(n - 1); } Console.WriteLine(Factorial(2544));
### Instruction: Write a function in C# that calculates the factorial of 2544. ### Response: static long Factorial(int n) { return n <= 1 ? 1 : n * Factorial(n - 1); } Console.WriteLine(Factorial(2544));
79,959
kk
Python
var_decl
beginner
Python тілінде 413204 мәнімен weight айнымалысын қалай жариялауға болады?
weight = 413204
### Instruction: Python тілінде 413204 мәнімен weight айнымалысын қалай жариялауға болады? ### Response: weight = 413204
95,548,339
ru
C#
string_ops
advanced
Напишите на C# функцию, которая проверяет, является ли строка палиндромом.
public bool IsPalindrome(string s) { int min = 0, max = s.Length - 1; while (min < max) { if (s[min] != s[max]) return false; min++; max--; } return true; }
### Instruction: Напишите на C# функцию, которая проверяет, является ли строка палиндромом. ### Response: public bool IsPalindrome(string s) { int min = 0, max = s.Length - 1; while (min < max) { if (s[min] != s[max]) return false; min++; max--; } return true; }
57,746,515
kk
C++
logic_ops
intermediate
C++ тилінде 1971 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
public bool IsLeap() { int y = 1971; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
### Instruction: C++ тилінде 1971 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. ### Response: public bool IsLeap() { int y = 1971; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
97,786,470
en
C++
string_ops
advanced
Write a function that checks if a string is a palindrome in C++.
public bool IsPalindrome(string s) { int min = 0, max = s.Length - 1; while (min < max) { if (s[min] != s[max]) return false; min++; max--; } return true; }
### Instruction: Write a function that checks if a string is a palindrome in C++. ### Response: public bool IsPalindrome(string s) { int min = 0, max = s.Length - 1; while (min < max) { if (s[min] != s[max]) return false; min++; max--; } return true; }
19,742,894
kk
Unity
logic_ops
advanced
Unity тилінде 300 санының жай сан екенін анықтайтын функцияны жазыңыз.
public bool IsPrime() { int n = 300; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
### Instruction: Unity тилінде 300 санының жай сан екенін анықтайтын функцияны жазыңыз. ### Response: public bool IsPrime() { int n = 300; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
399,702
kk
Python
factorial
advanced
Python тілінде 5898 санының факториалын есептейтін функция жаз.
def factorial(n): return 1 if n <= 1 else n * factorial(n - 1) print(factorial(5898))
### Instruction: Python тілінде 5898 санының факториалын есептейтін функция жаз. ### Response: def factorial(n): return 1 if n <= 1 else n * factorial(n - 1) print(factorial(5898))
10,672,909
kk
JavaScript
array_ops
intermediate
JavaScript тилінде тізімді керісінше айналдыратын функцияны жазыңыз.
const reverseArr = arr => arr.reverse();
### Instruction: JavaScript тилінде тізімді керісінше айналдыратын функцияны жазыңыз. ### Response: const reverseArr = arr => arr.reverse();
3,383,179
ru
C++
var_decl
beginner
Как объявить переменную value со значением 941573 в C++?
int value = 941573;
### Instruction: Как объявить переменную value со значением 941573 в C++? ### Response: int value = 941573;
76,696,818
ru
C#
string_ops
advanced
Напишите на C# функцию, которая проверяет, является ли строка палиндромом.
public bool IsPalindrome(string s) { int min = 0, max = s.Length - 1; while (min < max) { if (s[min] != s[max]) return false; min++; max--; } return true; }
### Instruction: Напишите на C# функцию, которая проверяет, является ли строка палиндромом. ### Response: public bool IsPalindrome(string s) { int min = 0, max = s.Length - 1; while (min < max) { if (s[min] != s[max]) return false; min++; max--; } return true; }
668,020
en
Unity
factorial
advanced
Write a function in Unity that calculates the factorial of 5433.
long Factorial(int n) { return n <= 1 ? 1 : n * Factorial(n - 1); } void Start() { Debug.Log(Factorial(5433)); }
### Instruction: Write a function in Unity that calculates the factorial of 5433. ### Response: long Factorial(int n) { return n <= 1 ? 1 : n * Factorial(n - 1); } void Start() { Debug.Log(Factorial(5433)); }
16,809,471
ru
Java
string_ops
intermediate
Напишите на Java функцию, которая проверяет, является ли строка палиндромом.
public bool IsPalindrome(string s) { int min = 0, max = s.Length - 1; while (min < max) { if (s[min] != s[max]) return false; min++; max--; } return true; }
### Instruction: Напишите на Java функцию, которая проверяет, является ли строка палиндромом. ### Response: public bool IsPalindrome(string s) { int min = 0, max = s.Length - 1; while (min < max) { if (s[min] != s[max]) return false; min++; max--; } return true; }
91,672,055
ru
C++
array_ops
advanced
Напишите на C++ функцию, которая разворачивает список задом наперед.
public void Reverse(int[] arr) { System.Array.Reverse(arr); }
### Instruction: Напишите на C++ функцию, которая разворачивает список задом наперед. ### Response: public void Reverse(int[] arr) { System.Array.Reverse(arr); }
3,752,931
ru
Unity
var_decl
beginner
Как объявить переменную result со значением 255778 в Unity?
int result = 255778;
### Instruction: Как объявить переменную result со значением 255778 в Unity? ### Response: int result = 255778;
4,437,123
ru
Python
var_decl
beginner
Как объявить переменную buffer со значением 767502 в Python?
buffer = 767502
### Instruction: Как объявить переменную buffer со значением 767502 в Python? ### Response: buffer = 767502
17,074,909
ru
C++
logic_ops
intermediate
Напишите на C++ логику проверки, является ли год 1952 високосным.
public bool IsLeap() { int y = 1952; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
### Instruction: Напишите на C++ логику проверки, является ли год 1952 високосным. ### Response: public bool IsLeap() { int y = 1952; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }