id int64 | language string | prog_lang string | category string | difficulty string | instruction string | output string | text string |
|---|---|---|---|---|---|---|---|
17,988,450 | en | Java | string_ops | intermediate | Write a function that converts a string to uppercase in Java. | public string ToUpper(string s) {
return s.ToUpper();
} | ### Instruction:
Write a function that converts a string to uppercase in Java.
### Response:
public string ToUpper(string s) {
return s.ToUpper();
} |
83,337,424 | kk | Python | array_ops | intermediate | Python тилінде тізімнен тек жұп сандарды сүзетін функцияны жазыңыз. | def filter_even(arr):
return [x for x in arr if x % 2 == 0] | ### Instruction:
Python тилінде тізімнен тек жұп сандарды сүзетін функцияны жазыңыз.
### Response:
def filter_even(arr):
return [x for x in arr if x % 2 == 0] |
616,641 | en | C# | var_decl | beginner | How to declare a variable score with value 286549 in C#? | int score = 286549; | ### Instruction:
How to declare a variable score with value 286549 in C#?
### Response:
int score = 286549; |
66,749,976 | ru | JavaScript | array_ops | intermediate | Напишите на JavaScript функцию, которая находит максимальное число в массиве. | const getMax = arr => Math.max(...arr); | ### Instruction:
Напишите на JavaScript функцию, которая находит максимальное число в массиве.
### Response:
const getMax = arr => Math.max(...arr); |
80,193,497 | 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);
} |
24,665,276 | kk | 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;
} |
136,002 | ru | Python | sum_n | intermediate | Напиши функцию на Python, которая считает сумму чисел от 1 до 1175. | def sum_to_n(n):
return sum(range(1, n + 1))
print(sum_to_n(1175)) | ### Instruction:
Напиши функцию на Python, которая считает сумму чисел от 1 до 1175.
### Response:
def sum_to_n(n):
return sum(range(1, n + 1))
print(sum_to_n(1175)) |
83,452,914 | kk | Python | array_ops | intermediate | Python тилінде тізімді керісінше айналдыратын функцияны жазыңыз. | def reverse_list(arr):
return arr[::-1] | ### Instruction:
Python тилінде тізімді керісінше айналдыратын функцияны жазыңыз.
### Response:
def reverse_list(arr):
return arr[::-1] |
19,123,755 | ru | Unity | array_ops | intermediate | Напишите на Unity функцию, которая фильтрует только четные числа из списка. | 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:
Напишите на Unity функцию, которая фильтрует только четные числа из списка.
### 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;
} |
10,653,574 | kk | JavaScript | logic_ops | intermediate | JavaScript тилінде 1946 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | function isLeap() {
let y = 1946;
return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0);
} | ### Instruction:
JavaScript тилінде 1946 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
function isLeap() {
let y = 1946;
return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0);
} |
70,270 | en | JavaScript | var_decl | beginner | How to declare a variable data with value 343475 in JavaScript? | let data = 343475; | ### Instruction:
How to declare a variable data with value 343475 in JavaScript?
### Response:
let data = 343475; |
26,155,117 | en | Unity | array_ops | intermediate | Write a function that filters only even numbers from a list in Unity. | 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:
Write a function that filters only even numbers from a list in Unity.
### 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;
} |
885,920 | ru | Python | var_decl | beginner | Как объявить переменную level со значением 332056 в Python? | level = 332056 | ### Instruction:
Как объявить переменную level со значением 332056 в Python?
### Response:
level = 332056 |
14,749,225 | ru | Unity | string_ops | intermediate | Напишите на Unity функцию, которая считает количество гласных букв в тексте. | public int CountVowels(string s) {
int c = 0;
foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++;
return c;
} | ### Instruction:
Напишите на Unity функцию, которая считает количество гласных букв в тексте.
### Response:
public int CountVowels(string s) {
int c = 0;
foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++;
return c;
} |
15,422,918 | kk | C# | logic_ops | advanced | C# тилінде 1924 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | public bool IsLeap() {
int y = 1924;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
C# тилінде 1924 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
public bool IsLeap() {
int y = 1924;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
96,078,842 | ru | C# | string_ops | intermediate | Напишите на C# функцию, которая переводит строку в верхний регистр. | public string ToUpper(string s) {
return s.ToUpper();
} | ### Instruction:
Напишите на C# функцию, которая переводит строку в верхний регистр.
### Response:
public string ToUpper(string s) {
return s.ToUpper();
} |
2,015,723 | en | Unity | var_decl | beginner | How to declare a variable index with value 58634 in Unity? | int index = 58634; | ### Instruction:
How to declare a variable index with value 58634 in Unity?
### Response:
int index = 58634; |
51,850,293 | en | C# | array_ops | intermediate | Write a function that reverses a list in C#. | public void Reverse(int[] arr) {
System.Array.Reverse(arr);
} | ### Instruction:
Write a function that reverses a list in C#.
### Response:
public void Reverse(int[] arr) {
System.Array.Reverse(arr);
} |
3,680,119 | kk | Java | var_decl | beginner | Java тілінде 99504 мәнімен rate айнымалысын қалай жариялауға болады? | int rate = 99504; | ### Instruction:
Java тілінде 99504 мәнімен rate айнымалысын қалай жариялауға болады?
### Response:
int rate = 99504; |
76,907,064 | ru | C# | string_ops | intermediate | Напишите на 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,915,143 | en | C++ | var_decl | beginner | How to declare a variable offset with value 474036 in C++? | int offset = 474036; | ### Instruction:
How to declare a variable offset with value 474036 in C++?
### Response:
int offset = 474036; |
97,828,628 | kk | C# | string_ops | advanced | C# тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз. | public string ToUpper(string s) {
return s.ToUpper();
} | ### Instruction:
C# тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз.
### Response:
public string ToUpper(string s) {
return s.ToUpper();
} |
76,283,870 | 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; |
92,290,827 | kk | Python | logic_ops | advanced | Python тилінде 1942 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | def is_leap():
year = 1942
return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0) | ### Instruction:
Python тилінде 1942 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
def is_leap():
year = 1942
return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0) |
43,266,719 | en | C++ | string_ops | advanced | 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();
} |
94,861,142 | ru | JavaScript | array_ops | intermediate | Напишите на JavaScript функцию, которая разворачивает список задом наперед. | const reverseArr = arr => arr.reverse(); | ### Instruction:
Напишите на JavaScript функцию, которая разворачивает список задом наперед.
### Response:
const reverseArr = arr => arr.reverse(); |
93,815,003 | 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();
} |
774,844 | kk | Java | var_decl | beginner | Java тілінде 345425 мәнімен size айнымалысын қалай жариялауға болады? | int size = 345425; | ### Instruction:
Java тілінде 345425 мәнімен size айнымалысын қалай жариялауға болады?
### Response:
int size = 345425; |
61,876,324 | kk | Python | string_ops | intermediate | 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аеёиоуыэюя') |
68,062,507 | en | C++ | logic_ops | intermediate | Write a function that determines if the number 414 is prime in C++. | public bool IsPrime() {
int n = 414;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
Write a function that determines if the number 414 is prime in C++.
### Response:
public bool IsPrime() {
int n = 414;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
48,799,136 | en | Unity | logic_ops | intermediate | Write a function that determines if the number 68 is prime in Unity. | public bool IsPrime() {
int n = 68;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
Write a function that determines if the number 68 is prime in Unity.
### Response:
public bool IsPrime() {
int n = 68;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
4,786,153 | ru | Unity | var_decl | beginner | Как объявить переменную timer со значением 51978 в Unity? | int timer = 51978; | ### Instruction:
Как объявить переменную timer со значением 51978 в Unity?
### Response:
int timer = 51978; |
35,661 | ru | C# | sum_n | intermediate | Напиши функцию на C#, которая считает сумму чисел от 1 до 2577. | static int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
Console.WriteLine(SumToN(2577)); | ### Instruction:
Напиши функцию на C#, которая считает сумму чисел от 1 до 2577.
### Response:
static int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
Console.WriteLine(SumToN(2577)); |
72,781,042 | en | JavaScript | string_ops | advanced | Write a function that checks if a string is a palindrome in JavaScript. | const isPalindrome = s => s === s.split('').reverse().join(''); | ### Instruction:
Write a function that checks if a string is a palindrome in JavaScript.
### Response:
const isPalindrome = s => s === s.split('').reverse().join(''); |
96,615,126 | en | C# | array_ops | advanced | Write a function that filters only even numbers from a list in 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:
Write a function that filters only even numbers from a list in 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;
} |
2,909,762 | kk | Unity | var_decl | beginner | Unity тілінде 403496 мәнімен count айнымалысын қалай жариялауға болады? | int count = 403496; | ### Instruction:
Unity тілінде 403496 мәнімен count айнымалысын қалай жариялауға болады?
### Response:
int count = 403496; |
87,451,675 | en | C++ | logic_ops | intermediate | Write a function that determines if the number 419 is prime in C++. | public bool IsPrime() {
int n = 419;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
Write a function that determines if the number 419 is prime in C++.
### Response:
public bool IsPrime() {
int n = 419;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
3,147,713 | en | Python | var_decl | beginner | How to declare a variable speed with value 552247 in Python? | speed = 552247 | ### Instruction:
How to declare a variable speed with value 552247 in Python?
### Response:
speed = 552247 |
61,615,924 | kk | Java | logic_ops | intermediate | Java тилінде 1916 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | public bool IsLeap() {
int y = 1916;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Java тилінде 1916 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
public bool IsLeap() {
int y = 1916;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
40,128,052 | kk | C# | array_ops | advanced | C# тилінде жиымдағы ең үлкен санды табатын функцияны жазыңыз. | public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} | ### Instruction:
C# тилінде жиымдағы ең үлкен санды табатын функцияны жазыңыз.
### Response:
public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} |
841,232 | ru | JavaScript | var_decl | beginner | Как объявить переменную rate со значением 928369 в JavaScript? | let rate = 928369; | ### Instruction:
Как объявить переменную rate со значением 928369 в JavaScript?
### Response:
let rate = 928369; |
433,118 | kk | Unity | sum_n | intermediate | Unity тілінде 1-ден 2996-ге дейінгі сандардың қосындысын есептейтін функция жаз. | int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
void Start() {
Debug.Log(SumToN(2996));
} | ### Instruction:
Unity тілінде 1-ден 2996-ге дейінгі сандардың қосындысын есептейтін функция жаз.
### Response:
int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
void Start() {
Debug.Log(SumToN(2996));
} |
76,338,175 | en | Python | array_ops | advanced | Write a function that reverses a list in Python. | def reverse_list(arr):
return arr[::-1] | ### Instruction:
Write a function that reverses a list in Python.
### Response:
def reverse_list(arr):
return arr[::-1] |
2,012,500 | en | JavaScript | var_decl | beginner | How to declare a variable value with value 896049 in JavaScript? | let value = 896049; | ### Instruction:
How to declare a variable value with value 896049 in JavaScript?
### Response:
let value = 896049; |
89,386,711 | ru | Unity | string_ops | intermediate | Напишите на 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:
Напишите на 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;
} |
3,439,773 | kk | JavaScript | var_decl | beginner | JavaScript тілінде 185402 мәнімен value айнымалысын қалай жариялауға болады? | let value = 185402; | ### Instruction:
JavaScript тілінде 185402 мәнімен value айнымалысын қалай жариялауға болады?
### Response:
let value = 185402; |
4,967,737 | en | Unity | var_decl | beginner | How to declare a variable value with value 629803 in Unity? | int value = 629803; | ### Instruction:
How to declare a variable value with value 629803 in Unity?
### Response:
int value = 629803; |
84,078,183 | 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;
} |
1,973,899 | kk | C++ | var_decl | beginner | C++ тілінде 443107 мәнімен offset айнымалысын қалай жариялауға болады? | int offset = 443107; | ### Instruction:
C++ тілінде 443107 мәнімен offset айнымалысын қалай жариялауға болады?
### Response:
int offset = 443107; |
4,150,771 | kk | C++ | var_decl | beginner | C++ тілінде 146016 мәнімен limit айнымалысын қалай жариялауға болады? | int limit = 146016; | ### Instruction:
C++ тілінде 146016 мәнімен limit айнымалысын қалай жариялауға болады?
### Response:
int limit = 146016; |
18,585,172 | ru | C++ | logic_ops | advanced | Напишите на C++ логику проверки, является ли год 1954 високосным. | public bool IsLeap() {
int y = 1954;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Напишите на C++ логику проверки, является ли год 1954 високосным.
### Response:
public bool IsLeap() {
int y = 1954;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
4,055,745 | en | Python | var_decl | beginner | How to declare a variable result with value 195448 in Python? | result = 195448 | ### Instruction:
How to declare a variable result with value 195448 in Python?
### Response:
result = 195448 |
76,447,383 | ru | Unity | array_ops | intermediate | Напишите на Unity функцию, которая разворачивает список задом наперед. | public void Reverse(int[] arr) {
System.Array.Reverse(arr);
} | ### Instruction:
Напишите на Unity функцию, которая разворачивает список задом наперед.
### Response:
public void Reverse(int[] arr) {
System.Array.Reverse(arr);
} |
97,984,911 | en | Unity | logic_ops | advanced | Write a function that determines if the number 312 is prime in Unity. | public bool IsPrime() {
int n = 312;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
Write a function that determines if the number 312 is prime in Unity.
### Response:
public bool IsPrime() {
int n = 312;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
87,023,122 | kk | Unity | logic_ops | advanced | Unity тилінде 450 санының жай сан екенін анықтайтын функцияны жазыңыз. | public bool IsPrime() {
int n = 450;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
Unity тилінде 450 санының жай сан екенін анықтайтын функцияны жазыңыз.
### Response:
public bool IsPrime() {
int n = 450;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
3,121,285 | kk | Python | var_decl | beginner | Python тілінде 898625 мәнімен y айнымалысын қалай жариялауға болады? | y = 898625 | ### Instruction:
Python тілінде 898625 мәнімен y айнымалысын қалай жариялауға болады?
### Response:
y = 898625 |
23,099,451 | ru | Python | array_ops | intermediate | Напишите на Python функцию, которая фильтрует только четные числа из списка. | def filter_even(arr):
return [x for x in arr if x % 2 == 0] | ### Instruction:
Напишите на Python функцию, которая фильтрует только четные числа из списка.
### Response:
def filter_even(arr):
return [x for x in arr if x % 2 == 0] |
1,320,193 | kk | Java | var_decl | beginner | Java тілінде 544943 мәнімен timer айнымалысын қалай жариялауға болады? | int timer = 544943; | ### Instruction:
Java тілінде 544943 мәнімен timer айнымалысын қалай жариялауға болады?
### Response:
int timer = 544943; |
10,120,535 | ru | JavaScript | string_ops | intermediate | Напишите на JavaScript функцию, которая проверяет, является ли строка палиндромом. | const isPalindrome = s => s === s.split('').reverse().join(''); | ### Instruction:
Напишите на JavaScript функцию, которая проверяет, является ли строка палиндромом.
### Response:
const isPalindrome = s => s === s.split('').reverse().join(''); |
889,732 | ru | Java | sum_n | intermediate | Напиши функцию на Java, которая считает сумму чисел от 1 до 5235. | static int sumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
System.out.println(sumToN(5235)); | ### Instruction:
Напиши функцию на Java, которая считает сумму чисел от 1 до 5235.
### Response:
static int sumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
System.out.println(sumToN(5235)); |
2,914,119 | ru | C++ | var_decl | beginner | Как объявить переменную y со значением 530016 в C++? | int y = 530016; | ### Instruction:
Как объявить переменную y со значением 530016 в C++?
### Response:
int y = 530016; |
138,156 | ru | C++ | sum_n | intermediate | Напиши функцию на C++, которая считает сумму чисел от 1 до 347. | int sum_to_n(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
std::cout << sum_to_n(347) << std::endl; | ### Instruction:
Напиши функцию на C++, которая считает сумму чисел от 1 до 347.
### Response:
int sum_to_n(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
std::cout << sum_to_n(347) << std::endl; |
80,182,990 | 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;
} |
1,494,075 | en | C++ | var_decl | beginner | How to declare a variable health with value 726075 in C++? | int health = 726075; | ### Instruction:
How to declare a variable health with value 726075 in C++?
### Response:
int health = 726075; |
41,380,336 | ru | C++ | string_ops | intermediate | Напишите на 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;
} |
62,322,201 | ru | 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);
} |
2,139,742 | ru | Unity | var_decl | beginner | Как объявить переменную amount со значением 822516 в Unity? | int amount = 822516; | ### Instruction:
Как объявить переменную amount со значением 822516 в Unity?
### Response:
int amount = 822516; |
3,103,258 | en | JavaScript | var_decl | beginner | How to declare a variable weight with value 826323 in JavaScript? | let weight = 826323; | ### Instruction:
How to declare a variable weight with value 826323 in JavaScript?
### Response:
let weight = 826323; |
4,032,238 | ru | Python | var_decl | beginner | Как объявить переменную rate со значением 910937 в Python? | rate = 910937 | ### Instruction:
Как объявить переменную rate со значением 910937 в Python?
### Response:
rate = 910937 |
57,951,953 | kk | C# | array_ops | intermediate | C# тилінде жиымдағы ең үлкен санды табатын функцияны жазыңыз. | public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} | ### Instruction:
C# тилінде жиымдағы ең үлкен санды табатын функцияны жазыңыз.
### Response:
public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} |
3,278,858 | en | C# | var_decl | beginner | How to declare a variable data with value 344477 in C#? | int data = 344477; | ### Instruction:
How to declare a variable data with value 344477 in C#?
### Response:
int data = 344477; |
23,333,756 | en | Unity | logic_ops | intermediate | Write logic to check if the year 1979 is a leap year in Unity. | public bool IsLeap() {
int y = 1979;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Write logic to check if the year 1979 is a leap year in Unity.
### Response:
public bool IsLeap() {
int y = 1979;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
41,228,494 | 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);
} |
86,490,994 | ru | Java | logic_ops | advanced | Напишите на Java логику проверки, является ли год 2044 високосным. | public bool IsLeap() {
int y = 2044;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Напишите на Java логику проверки, является ли год 2044 високосным.
### Response:
public bool IsLeap() {
int y = 2044;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
60,292,193 | kk | JavaScript | logic_ops | advanced | JavaScript тилінде 2046 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | function isLeap() {
let y = 2046;
return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0);
} | ### Instruction:
JavaScript тилінде 2046 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
function isLeap() {
let y = 2046;
return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0);
} |
322,646 | en | Java | sum_n | intermediate | Write a function in Java that sums numbers from 1 to 2300. | static int sumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
System.out.println(sumToN(2300)); | ### Instruction:
Write a function in Java that sums numbers from 1 to 2300.
### Response:
static int sumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
System.out.println(sumToN(2300)); |
1,971,725 | kk | C# | var_decl | beginner | C# тілінде 941645 мәнімен total айнымалысын қалай жариялауға болады? | int total = 941645; | ### Instruction:
C# тілінде 941645 мәнімен total айнымалысын қалай жариялауға болады?
### Response:
int total = 941645; |
4,794,722 | en | C# | var_decl | beginner | How to declare a variable score with value 433527 in C#? | int score = 433527; | ### Instruction:
How to declare a variable score with value 433527 in C#?
### Response:
int score = 433527; |
2,336,729 | kk | C# | var_decl | beginner | C# тілінде 563495 мәнімен amount айнымалысын қалай жариялауға болады? | int amount = 563495; | ### Instruction:
C# тілінде 563495 мәнімен amount айнымалысын қалай жариялауға болады?
### Response:
int amount = 563495; |
71,145,538 | ru | C++ | array_ops | advanced | Напишите на C++ функцию, которая находит максимальное число в массиве. | public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} | ### Instruction:
Напишите на C++ функцию, которая находит максимальное число в массиве.
### Response:
public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} |
79,116,085 | ru | C++ | logic_ops | intermediate | Напишите на C++ логику проверки, является ли год 2027 високосным. | public bool IsLeap() {
int y = 2027;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Напишите на C++ логику проверки, является ли год 2027 високосным.
### Response:
public bool IsLeap() {
int y = 2027;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
1,108,338 | ru | Java | var_decl | beginner | Как объявить переменную weight со значением 653725 в Java? | int weight = 653725; | ### Instruction:
Как объявить переменную weight со значением 653725 в Java?
### Response:
int weight = 653725; |
48,750,464 | kk | Python | logic_ops | advanced | Python тилінде 194 санының жай сан екенін анықтайтын функцияны жазыңыз. | def is_prime():
n = 194
return n > 1 and all(n % i != 0 for i in range(2, int(n**0.5) + 1)) | ### Instruction:
Python тилінде 194 санының жай сан екенін анықтайтын функцияны жазыңыз.
### Response:
def is_prime():
n = 194
return n > 1 and all(n % i != 0 for i in range(2, int(n**0.5) + 1)) |
68,706,000 | en | C# | array_ops | advanced | Write a function that filters only even numbers from a list in 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:
Write a function that filters only even numbers from a list in 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;
} |
55,995,282 | kk | 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);
} |
836,963 | en | C# | var_decl | beginner | How to declare a variable speed with value 426640 in C#? | int speed = 426640; | ### Instruction:
How to declare a variable speed with value 426640 in C#?
### Response:
int speed = 426640; |
471,775 | en | C++ | factorial | advanced | Write a function in C++ that calculates the factorial of 1406. | long long factorial(int n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
std::cout << factorial(1406) << std::endl; | ### Instruction:
Write a function in C++ that calculates the factorial of 1406.
### Response:
long long factorial(int n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
std::cout << factorial(1406) << std::endl; |
2,370,455 | kk | Unity | var_decl | beginner | Unity тілінде 410362 мәнімен limit айнымалысын қалай жариялауға болады? | int limit = 410362; | ### Instruction:
Unity тілінде 410362 мәнімен limit айнымалысын қалай жариялауға болады?
### Response:
int limit = 410362; |
10,516,356 | ru | Unity | string_ops | advanced | Напишите на Unity функцию, которая переводит строку в верхний регистр. | public string ToUpper(string s) {
return s.ToUpper();
} | ### Instruction:
Напишите на Unity функцию, которая переводит строку в верхний регистр.
### Response:
public string ToUpper(string s) {
return s.ToUpper();
} |
67,473,568 | ru | C# | logic_ops | advanced | Напишите на C# логику проверки, является ли год 1995 високосным. | public bool IsLeap() {
int y = 1995;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Напишите на C# логику проверки, является ли год 1995 високосным.
### Response:
public bool IsLeap() {
int y = 1995;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
2,580,585 | en | C# | var_decl | beginner | How to declare a variable value with value 960719 in C#? | int value = 960719; | ### Instruction:
How to declare a variable value with value 960719 in C#?
### Response:
int value = 960719; |
58,944,981 | kk | Java | logic_ops | intermediate | Java тилінде 2100 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | public bool IsLeap() {
int y = 2100;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Java тилінде 2100 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
public bool IsLeap() {
int y = 2100;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
25,688,759 | kk | Java | string_ops | advanced | Java тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз. | public string ToUpper(string s) {
return s.ToUpper();
} | ### Instruction:
Java тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз.
### Response:
public string ToUpper(string s) {
return s.ToUpper();
} |
36,208,368 | en | Java | string_ops | intermediate | Write a function that counts vowels in a text in Java. | 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 Java.
### Response:
public int CountVowels(string s) {
int c = 0;
foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++;
return c;
} |
1,798,396 | en | C# | var_decl | beginner | How to declare a variable speed with value 180411 in C#? | int speed = 180411; | ### Instruction:
How to declare a variable speed with value 180411 in C#?
### Response:
int speed = 180411; |
2,073,371 | kk | C# | var_decl | beginner | C# тілінде 194426 мәнімен health айнымалысын қалай жариялауға болады? | int health = 194426; | ### Instruction:
C# тілінде 194426 мәнімен health айнымалысын қалай жариялауға болады?
### Response:
int health = 194426; |
3,233,182 | en | Python | var_decl | beginner | How to declare a variable value with value 276337 in Python? | value = 276337 | ### Instruction:
How to declare a variable value with value 276337 in Python?
### Response:
value = 276337 |
569,188 | kk | C# | var_decl | beginner | C# тілінде 565896 мәнімен total айнымалысын қалай жариялауға болады? | int total = 565896; | ### Instruction:
C# тілінде 565896 мәнімен total айнымалысын қалай жариялауға болады?
### Response:
int total = 565896; |
3,779,339 | ru | Python | var_decl | beginner | Как объявить переменную index со значением 820608 в Python? | index = 820608 | ### Instruction:
Как объявить переменную index со значением 820608 в Python?
### Response:
index = 820608 |
86,152,603 | en | Unity | logic_ops | advanced | Write a function that determines if the number 363 is prime in Unity. | public bool IsPrime() {
int n = 363;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
Write a function that determines if the number 363 is prime in Unity.
### Response:
public bool IsPrime() {
int n = 363;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.