id
int64
language
string
prog_lang
string
category
string
difficulty
string
instruction
string
output
string
text
string
56,081
ru
C++
sum_n
intermediate
Напиши функцию на C++, которая считает сумму чисел от 1 до 8.
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(8) << std::endl;
### Instruction: Напиши функцию на C++, которая считает сумму чисел от 1 до 8. ### 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(8) << std::endl;
88,876,461
kk
JavaScript
string_ops
advanced
JavaScript тилінде мәтіндегі дауысты әріптердің санын есептейтін функцияны жазыңыз.
const countVowels = s => (s.match(/[aeiou]/gi) || []).length;
### Instruction: JavaScript тилінде мәтіндегі дауысты әріптердің санын есептейтін функцияны жазыңыз. ### Response: const countVowels = s => (s.match(/[aeiou]/gi) || []).length;
36,264,194
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); }
1,903,189
ru
JavaScript
var_decl
beginner
Как объявить переменную total со значением 112360 в JavaScript?
let total = 112360;
### Instruction: Как объявить переменную total со значением 112360 в JavaScript? ### Response: let total = 112360;
2,696,070
ru
JavaScript
var_decl
beginner
Как объявить переменную speed со значением 800007 в JavaScript?
let speed = 800007;
### Instruction: Как объявить переменную speed со значением 800007 в JavaScript? ### Response: let speed = 800007;
33,893,901
ru
Python
array_ops
intermediate
Напишите на Python функцию, которая разворачивает список задом наперед.
def reverse_list(arr): return arr[::-1]
### Instruction: Напишите на Python функцию, которая разворачивает список задом наперед. ### Response: def reverse_list(arr): return arr[::-1]
2,576,332
kk
C++
var_decl
beginner
C++ тілінде 610115 мәнімен speed айнымалысын қалай жариялауға болады?
int speed = 610115;
### Instruction: C++ тілінде 610115 мәнімен speed айнымалысын қалай жариялауға болады? ### Response: int speed = 610115;
3,014,044
ru
Java
var_decl
beginner
Как объявить переменную health со значением 265197 в Java?
int health = 265197;
### Instruction: Как объявить переменную health со значением 265197 в Java? ### Response: int health = 265197;
80,896,687
en
Python
string_ops
intermediate
Write a function that converts a string to uppercase in Python.
def to_upper(s): return s.upper()
### Instruction: Write a function that converts a string to uppercase in Python. ### Response: def to_upper(s): return s.upper()
131,227
en
C#
sum_n
intermediate
Write a function in C# that sums numbers from 1 to 1741.
static int SumToN(int n) { int s = 0; for (int i = 1; i <= n; i++) s += i; return s; } Console.WriteLine(SumToN(1741));
### Instruction: Write a function in C# that sums numbers from 1 to 1741. ### Response: static int SumToN(int n) { int s = 0; for (int i = 1; i <= n; i++) s += i; return s; } Console.WriteLine(SumToN(1741));
222,328
kk
Java
sum_n
intermediate
Java тілінде 1-ден 5803-ге дейінгі сандардың қосындысын есептейтін функция жаз.
static int sumToN(int n) { int s = 0; for (int i = 1; i <= n; i++) s += i; return s; } System.out.println(sumToN(5803));
### Instruction: Java тілінде 1-ден 5803-ге дейінгі сандардың қосындысын есептейтін функция жаз. ### Response: static int sumToN(int n) { int s = 0; for (int i = 1; i <= n; i++) s += i; return s; } System.out.println(sumToN(5803));
3,793,830
en
C#
var_decl
beginner
How to declare a variable y with value 274230 in C#?
int y = 274230;
### Instruction: How to declare a variable y with value 274230 in C#? ### Response: int y = 274230;
4,850,364
en
Python
var_decl
beginner
How to declare a variable data with value 506822 in Python?
data = 506822
### Instruction: How to declare a variable data with value 506822 in Python? ### Response: data = 506822
4,628,440
ru
Java
var_decl
beginner
Как объявить переменную count со значением 658433 в Java?
int count = 658433;
### Instruction: Как объявить переменную count со значением 658433 в Java? ### Response: int count = 658433;
11,738,880
kk
Java
array_ops
advanced
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; }
516,239
ru
Python
var_decl
beginner
Как объявить переменную total со значением 550963 в Python?
total = 550963
### Instruction: Как объявить переменную total со значением 550963 в Python? ### Response: total = 550963
41,594,619
kk
JavaScript
logic_ops
intermediate
JavaScript тилінде 1974 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
function isLeap() { let y = 1974; return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0); }
### Instruction: JavaScript тилінде 1974 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. ### Response: function isLeap() { let y = 1974; return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0); }
58,875,410
en
Java
array_ops
intermediate
Write a function that filters only even numbers from a list in Java.
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 Java. ### 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; }
3,769,954
ru
JavaScript
var_decl
beginner
Как объявить переменную level со значением 573337 в JavaScript?
let level = 573337;
### Instruction: Как объявить переменную level со значением 573337 в JavaScript? ### Response: let level = 573337;
4,866,784
kk
Python
var_decl
beginner
Python тілінде 934339 мәнімен rate айнымалысын қалай жариялауға болады?
rate = 934339
### Instruction: Python тілінде 934339 мәнімен rate айнымалысын қалай жариялауға болады? ### Response: rate = 934339
1,354,082
en
Python
var_decl
beginner
How to declare a variable timer with value 530295 in Python?
timer = 530295
### Instruction: How to declare a variable timer with value 530295 in Python? ### Response: timer = 530295
2,556,979
ru
Unity
var_decl
beginner
Как объявить переменную timer со значением 707938 в Unity?
int timer = 707938;
### Instruction: Как объявить переменную timer со значением 707938 в Unity? ### Response: int timer = 707938;
1,310,828
en
Unity
var_decl
beginner
How to declare a variable count with value 974472 in Unity?
int count = 974472;
### Instruction: How to declare a variable count with value 974472 in Unity? ### Response: int count = 974472;
239,939
en
JavaScript
factorial
advanced
Write a function in JavaScript that calculates the factorial of 1859.
function factorial(n) { return n <= 1 ? 1 : n * factorial(n - 1); } console.log(factorial(1859));
### Instruction: Write a function in JavaScript that calculates the factorial of 1859. ### Response: function factorial(n) { return n <= 1 ? 1 : n * factorial(n - 1); } console.log(factorial(1859));
4,112,017
kk
Python
var_decl
beginner
Python тілінде 612163 мәнімен total айнымалысын қалай жариялауға болады?
total = 612163
### Instruction: Python тілінде 612163 мәнімен total айнымалысын қалай жариялауға болады? ### Response: total = 612163
99,753,717
en
C++
logic_ops
advanced
Write logic to check if the year 1943 is a leap year in C++.
public bool IsLeap() { int y = 1943; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
### Instruction: Write logic to check if the year 1943 is a leap year in C++. ### Response: public bool IsLeap() { int y = 1943; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
80,821,943
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); }
86,721,056
kk
JavaScript
string_ops
intermediate
JavaScript тилінде жолдың палиндром екенін тексеретін функцияны жазыңыз.
const isPalindrome = s => s === s.split('').reverse().join('');
### Instruction: JavaScript тилінде жолдың палиндром екенін тексеретін функцияны жазыңыз. ### Response: const isPalindrome = s => s === s.split('').reverse().join('');
43,038,668
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; }
22,197,100
ru
Unity
string_ops
advanced
Напишите на 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; }
54,531,544
kk
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; }
66,921,579
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; }
86,264,960
en
Java
logic_ops
intermediate
Write a function that determines if the number 276 is prime in Java.
public bool IsPrime() { int n = 276; 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 276 is prime in Java. ### Response: public bool IsPrime() { int n = 276; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
59,391,956
en
C#
array_ops
advanced
Write a function that finds the maximum number in an array in C#.
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 C#. ### Response: public int GetMax(int[] arr) { int max = arr[0]; foreach(int x in arr) if(x > max) max = x; return max; }
81,921,380
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(); }
39,854,509
ru
Python
logic_ops
advanced
Напишите на Python логику проверки, является ли год 2079 високосным.
def is_leap(): year = 2079 return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0)
### Instruction: Напишите на Python логику проверки, является ли год 2079 високосным. ### Response: def is_leap(): year = 2079 return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0)
1,311,332
kk
Python
var_decl
beginner
Python тілінде 294070 мәнімен score айнымалысын қалай жариялауға болады?
score = 294070
### Instruction: Python тілінде 294070 мәнімен score айнымалысын қалай жариялауға болады? ### Response: score = 294070
273,954
ru
C++
factorial
advanced
Напиши функцию на C++, которая вычисляет факториал числа 2994.
long long factorial(int n) { return n <= 1 ? 1 : n * factorial(n - 1); } std::cout << factorial(2994) << std::endl;
### Instruction: Напиши функцию на C++, которая вычисляет факториал числа 2994. ### Response: long long factorial(int n) { return n <= 1 ? 1 : n * factorial(n - 1); } std::cout << factorial(2994) << std::endl;
10,551,545
kk
Java
string_ops
advanced
Java тилінде мәтіндегі дауысты әріптердің санын есептейтін функцияны жазыңыз.
public int CountVowels(string s) { int c = 0; foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++; return c; }
### Instruction: Java тилінде мәтіндегі дауысты әріптердің санын есептейтін функцияны жазыңыз. ### Response: public int CountVowels(string s) { int c = 0; foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++; return c; }
787,050
kk
C++
var_decl
beginner
C++ тілінде 355726 мәнімен amount айнымалысын қалай жариялауға болады?
int amount = 355726;
### Instruction: C++ тілінде 355726 мәнімен amount айнымалысын қалай жариялауға болады? ### Response: int amount = 355726;
53,672,158
ru
JavaScript
array_ops
intermediate
Напишите на JavaScript функцию, которая находит максимальное число в массиве.
const getMax = arr => Math.max(...arr);
### Instruction: Напишите на JavaScript функцию, которая находит максимальное число в массиве. ### Response: const getMax = arr => Math.max(...arr);
56,289,721
en
Python
string_ops
advanced
Write a function that checks if a string is a palindrome in Python.
def is_palindrome(s): return s == s[::-1]
### Instruction: Write a function that checks if a string is a palindrome in Python. ### Response: def is_palindrome(s): return s == s[::-1]
246,718
en
JavaScript
factorial
advanced
Write a function in JavaScript that calculates the factorial of 1648.
function factorial(n) { return n <= 1 ? 1 : n * factorial(n - 1); } console.log(factorial(1648));
### Instruction: Write a function in JavaScript that calculates the factorial of 1648. ### Response: function factorial(n) { return n <= 1 ? 1 : n * factorial(n - 1); } console.log(factorial(1648));
932,047
kk
C#
var_decl
beginner
C# тілінде 229022 мәнімен offset айнымалысын қалай жариялауға болады?
int offset = 229022;
### Instruction: C# тілінде 229022 мәнімен offset айнымалысын қалай жариялауға болады? ### Response: int offset = 229022;
77,876,214
ru
Unity
array_ops
advanced
Напишите на Unity функцию, которая находит максимальное число в массиве.
public int GetMax(int[] arr) { int max = arr[0]; foreach(int x in arr) if(x > max) max = x; return max; }
### Instruction: Напишите на Unity функцию, которая находит максимальное число в массиве. ### Response: public int GetMax(int[] arr) { int max = arr[0]; foreach(int x in arr) if(x > max) max = x; return max; }
3,327,116
kk
C++
var_decl
beginner
C++ тілінде 709565 мәнімен total айнымалысын қалай жариялауға болады?
int total = 709565;
### Instruction: C++ тілінде 709565 мәнімен total айнымалысын қалай жариялауға болады? ### Response: int total = 709565;
1,041,201
kk
C++
var_decl
beginner
C++ тілінде 881138 мәнімен total айнымалысын қалай жариялауға болады?
int total = 881138;
### Instruction: C++ тілінде 881138 мәнімен total айнымалысын қалай жариялауға болады? ### Response: int total = 881138;
4,892,530
ru
Java
var_decl
beginner
Как объявить переменную level со значением 908460 в Java?
int level = 908460;
### Instruction: Как объявить переменную level со значением 908460 в Java? ### Response: int level = 908460;
87,472,566
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]
68,020,088
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; }
43,742,417
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аеёиоуыэюя')
47,159,966
en
Python
logic_ops
intermediate
Write a function that determines if the number 116 is prime in Python.
def is_prime(): n = 116 return n > 1 and all(n % i != 0 for i in range(2, int(n**0.5) + 1))
### Instruction: Write a function that determines if the number 116 is prime in Python. ### Response: def is_prime(): n = 116 return n > 1 and all(n % i != 0 for i in range(2, int(n**0.5) + 1))
64,051,482
en
Java
string_ops
advanced
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(); }
89,457,419
en
Java
array_ops
intermediate
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); }
42,673,143
en
Java
string_ops
advanced
Write a function that checks if a string is a palindrome in 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: Write a function that checks if a string is a palindrome in 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; }
36,269,562
en
Unity
logic_ops
advanced
Write a function that determines if the number 42 is prime in Unity.
public bool IsPrime() { int n = 42; 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 42 is prime in Unity. ### Response: public bool IsPrime() { int n = 42; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
63,925,303
kk
Java
array_ops
intermediate
Java тилінде тізімнен тек жұп сандарды сүзетін функцияны жазыңыз.
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: Java тилінде тізімнен тек жұп сандарды сүзетін функцияны жазыңыз. ### 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; }
98,325,222
ru
JavaScript
array_ops
intermediate
Напишите на JavaScript функцию, которая разворачивает список задом наперед.
const reverseArr = arr => arr.reverse();
### Instruction: Напишите на JavaScript функцию, которая разворачивает список задом наперед. ### Response: const reverseArr = arr => arr.reverse();
52,768,484
en
Python
array_ops
advanced
Write a function that filters only even numbers from a list in Python.
def filter_even(arr): return [x for x in arr if x % 2 == 0]
### Instruction: Write a function that filters only even numbers from a list in Python. ### Response: def filter_even(arr): return [x for x in arr if x % 2 == 0]
63,206,756
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; }
76,732,845
en
Python
array_ops
intermediate
Write a function that filters only even numbers from a list in Python.
def filter_even(arr): return [x for x in arr if x % 2 == 0]
### Instruction: Write a function that filters only even numbers from a list in Python. ### Response: def filter_even(arr): return [x for x in arr if x % 2 == 0]
392,231
ru
Java
sum_n
intermediate
Напиши функцию на Java, которая считает сумму чисел от 1 до 5940.
static int sumToN(int n) { int s = 0; for (int i = 1; i <= n; i++) s += i; return s; } System.out.println(sumToN(5940));
### Instruction: Напиши функцию на Java, которая считает сумму чисел от 1 до 5940. ### Response: static int sumToN(int n) { int s = 0; for (int i = 1; i <= n; i++) s += i; return s; } System.out.println(sumToN(5940));
65,736,260
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(); }
40,082,930
ru
Java
logic_ops
advanced
Напишите на Java функцию, определяющую, является ли число 107 простым.
public bool IsPrime() { int n = 107; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
### Instruction: Напишите на Java функцию, определяющую, является ли число 107 простым. ### Response: public bool IsPrime() { int n = 107; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
66,034,320
ru
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аеёиоуыэюя')
1,911,770
kk
Java
var_decl
beginner
Java тілінде 276166 мәнімен size айнымалысын қалай жариялауға болады?
int size = 276166;
### Instruction: Java тілінде 276166 мәнімен size айнымалысын қалай жариялауға болады? ### Response: int size = 276166;
69,215,548
ru
Python
array_ops
intermediate
Напишите на Python функцию, которая разворачивает список задом наперед.
def reverse_list(arr): return arr[::-1]
### Instruction: Напишите на Python функцию, которая разворачивает список задом наперед. ### Response: def reverse_list(arr): return arr[::-1]
10,161,337
ru
C#
logic_ops
advanced
Напишите на C# логику проверки, является ли год 1911 високосным.
public bool IsLeap() { int y = 1911; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
### Instruction: Напишите на C# логику проверки, является ли год 1911 високосным. ### Response: public bool IsLeap() { int y = 1911; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
1,151,847
kk
Python
var_decl
beginner
Python тілінде 751758 мәнімен value айнымалысын қалай жариялауға болады?
value = 751758
### Instruction: Python тілінде 751758 мәнімен value айнымалысын қалай жариялауға болады? ### Response: value = 751758
27,405,094
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; }
2,302,344
en
JavaScript
var_decl
beginner
How to declare a variable offset with value 926653 in JavaScript?
let offset = 926653;
### Instruction: How to declare a variable offset with value 926653 in JavaScript? ### Response: let offset = 926653;
18,841,454
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(); }
60,561,218
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; }
2,599,717
en
C#
var_decl
beginner
How to declare a variable count with value 54980 in C#?
int count = 54980;
### Instruction: How to declare a variable count with value 54980 in C#? ### Response: int count = 54980;
39,857,145
kk
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; }
18,358,438
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); }
25,051,360
kk
JavaScript
logic_ops
intermediate
JavaScript тилінде 1942 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
function isLeap() { let y = 1942; return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0); }
### Instruction: JavaScript тилінде 1942 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. ### Response: function isLeap() { let y = 1942; return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0); }
82,309,802
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; }
4,729,338
en
JavaScript
var_decl
beginner
How to declare a variable level with value 868843 in JavaScript?
let level = 868843;
### Instruction: How to declare a variable level with value 868843 in JavaScript? ### Response: let level = 868843;
64,892,810
kk
C++
logic_ops
intermediate
C++ тилінде 1919 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
public bool IsLeap() { int y = 1919; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
### Instruction: C++ тилінде 1919 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. ### Response: public bool IsLeap() { int y = 1919; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
19,798,880
kk
JavaScript
array_ops
advanced
JavaScript тилінде тізімді керісінше айналдыратын функцияны жазыңыз.
const reverseArr = arr => arr.reverse();
### Instruction: JavaScript тилінде тізімді керісінше айналдыратын функцияны жазыңыз. ### Response: const reverseArr = arr => arr.reverse();
80,858,060
ru
C++
logic_ops
advanced
Напишите на C++ логику проверки, является ли год 1923 високосным.
public bool IsLeap() { int y = 1923; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
### Instruction: Напишите на C++ логику проверки, является ли год 1923 високосным. ### Response: public bool IsLeap() { int y = 1923; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
68,922,936
ru
Unity
string_ops
intermediate
Напишите на Unity функцию, которая переводит строку в верхний регистр.
public string ToUpper(string s) { return s.ToUpper(); }
### Instruction: Напишите на Unity функцию, которая переводит строку в верхний регистр. ### Response: public string ToUpper(string s) { return s.ToUpper(); }
2,559,837
en
C#
var_decl
beginner
How to declare a variable value with value 794957 in C#?
int value = 794957;
### Instruction: How to declare a variable value with value 794957 in C#? ### Response: int value = 794957;
4,103,598
ru
C++
var_decl
beginner
Как объявить переменную level со значением 909039 в C++?
int level = 909039;
### Instruction: Как объявить переменную level со значением 909039 в C++? ### Response: int level = 909039;
2,516,044
en
C#
var_decl
beginner
How to declare a variable x with value 771811 in C#?
int x = 771811;
### Instruction: How to declare a variable x with value 771811 in C#? ### Response: int x = 771811;
1,583,823
en
Unity
var_decl
beginner
How to declare a variable result with value 65933 in Unity?
int result = 65933;
### Instruction: How to declare a variable result with value 65933 in Unity? ### Response: int result = 65933;
38,866,622
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(); }
63,762,660
kk
C++
logic_ops
intermediate
C++ тилінде 330 санының жай сан екенін анықтайтын функцияны жазыңыз.
public bool IsPrime() { int n = 330; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
### Instruction: C++ тилінде 330 санының жай сан екенін анықтайтын функцияны жазыңыз. ### Response: public bool IsPrime() { int n = 330; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
63,215,462
en
JavaScript
array_ops
advanced
Write a function that reverses a list in JavaScript.
const reverseArr = arr => arr.reverse();
### Instruction: Write a function that reverses a list in JavaScript. ### Response: const reverseArr = arr => arr.reverse();
3,931,534
kk
Unity
var_decl
beginner
Unity тілінде 207335 мәнімен score айнымалысын қалай жариялауға болады?
int score = 207335;
### Instruction: Unity тілінде 207335 мәнімен score айнымалысын қалай жариялауға болады? ### Response: int score = 207335;
99,539,001
en
Python
logic_ops
advanced
Write logic to check if the year 2093 is a leap year in Python.
def is_leap(): year = 2093 return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0)
### Instruction: Write logic to check if the year 2093 is a leap year in Python. ### Response: def is_leap(): year = 2093 return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0)
4,101,388
ru
JavaScript
var_decl
beginner
Как объявить переменную offset со значением 108648 в JavaScript?
let offset = 108648;
### Instruction: Как объявить переменную offset со значением 108648 в JavaScript? ### Response: let offset = 108648;
54,248,464
ru
Unity
logic_ops
intermediate
Напишите на Unity логику проверки, является ли год 1905 високосным.
public bool IsLeap() { int y = 1905; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
### Instruction: Напишите на Unity логику проверки, является ли год 1905 високосным. ### Response: public bool IsLeap() { int y = 1905; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
83,218,224
en
JavaScript
array_ops
intermediate
Write a function that filters only even numbers from a list in JavaScript.
const filterEven = arr => arr.filter(x => x % 2 === 0);
### Instruction: Write a function that filters only even numbers from a list in JavaScript. ### Response: const filterEven = arr => arr.filter(x => x % 2 === 0);
3,081,527
kk
C++
var_decl
beginner
C++ тілінде 80777 мәнімен value айнымалысын қалай жариялауға болады?
int value = 80777;
### Instruction: C++ тілінде 80777 мәнімен value айнымалысын қалай жариялауға болады? ### Response: int value = 80777;
48,858,364
en
Java
array_ops
intermediate
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); }
62,192,463
kk
Java
logic_ops
intermediate
Java тилінде 1946 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
public bool IsLeap() { int y = 1946; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
### Instruction: Java тилінде 1946 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. ### Response: public bool IsLeap() { int y = 1946; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
4,750,223
ru
Unity
var_decl
beginner
Как объявить переменную rate со значением 665561 в Unity?
int rate = 665561;
### Instruction: Как объявить переменную rate со значением 665561 в Unity? ### Response: int rate = 665561;
4,159,484
kk
C#
var_decl
beginner
C# тілінде 459528 мәнімен total айнымалысын қалай жариялауға болады?
int total = 459528;
### Instruction: C# тілінде 459528 мәнімен total айнымалысын қалай жариялауға болады? ### Response: int total = 459528;