id int64 | language string | prog_lang string | category string | difficulty string | instruction string | output string | text string |
|---|---|---|---|---|---|---|---|
11,210,520 | en | JavaScript | logic_ops | advanced | Write logic to check if the year 2099 is a leap year in JavaScript. | function isLeap() {
let y = 2099;
return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0);
} | ### Instruction:
Write logic to check if the year 2099 is a leap year in JavaScript.
### Response:
function isLeap() {
let y = 2099;
return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0);
} |
75,480,299 | ru | Python | string_ops | advanced | Напишите на Python функцию, которая переводит строку в верхний регистр. | def to_upper(s):
return s.upper() | ### Instruction:
Напишите на Python функцию, которая переводит строку в верхний регистр.
### Response:
def to_upper(s):
return s.upper() |
57,958,517 | 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;
} |
2,219,297 | ru | C# | var_decl | beginner | Как объявить переменную value со значением 523027 в C#? | int value = 523027; | ### Instruction:
Как объявить переменную value со значением 523027 в C#?
### Response:
int value = 523027; |
58,779,150 | kk | 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,191,290 | ru | Unity | var_decl | beginner | Как объявить переменную limit со значением 17369 в Unity? | int limit = 17369; | ### Instruction:
Как объявить переменную limit со значением 17369 в Unity?
### Response:
int limit = 17369; |
91,056,060 | 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); |
169,533 | en | C# | factorial | advanced | Write a function in C# that calculates the factorial of 3096. | static long Factorial(int n) {
return n <= 1 ? 1 : n * Factorial(n - 1);
}
Console.WriteLine(Factorial(3096)); | ### Instruction:
Write a function in C# that calculates the factorial of 3096.
### Response:
static long Factorial(int n) {
return n <= 1 ? 1 : n * Factorial(n - 1);
}
Console.WriteLine(Factorial(3096)); |
1,788,025 | ru | C# | var_decl | beginner | Как объявить переменную x со значением 931906 в C#? | int x = 931906; | ### Instruction:
Как объявить переменную x со значением 931906 в C#?
### Response:
int x = 931906; |
86,198,119 | 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();
} |
95,055,660 | en | Python | array_ops | intermediate | 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] |
3,645,284 | ru | JavaScript | var_decl | beginner | Как объявить переменную health со значением 443701 в JavaScript? | let health = 443701; | ### Instruction:
Как объявить переменную health со значением 443701 в JavaScript?
### Response:
let health = 443701; |
253,860 | ru | C++ | factorial | advanced | Напиши функцию на C++, которая вычисляет факториал числа 8605. | long long factorial(int n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
std::cout << factorial(8605) << std::endl; | ### Instruction:
Напиши функцию на C++, которая вычисляет факториал числа 8605.
### Response:
long long factorial(int n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
std::cout << factorial(8605) << std::endl; |
1,309,244 | kk | C++ | var_decl | beginner | C++ тілінде 648980 мәнімен speed айнымалысын қалай жариялауға болады? | int speed = 648980; | ### Instruction:
C++ тілінде 648980 мәнімен speed айнымалысын қалай жариялауға болады?
### Response:
int speed = 648980; |
10,888,420 | ru | JavaScript | logic_ops | intermediate | Напишите на JavaScript функцию, определяющую, является ли число 388 простым. | function isPrime() {
let n = 388;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} | ### Instruction:
Напишите на JavaScript функцию, определяющую, является ли число 388 простым.
### Response:
function isPrime() {
let n = 388;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} |
89,564,826 | 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);
} |
64,005,911 | 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;
} |
4,951,458 | ru | Java | var_decl | beginner | Как объявить переменную total со значением 22698 в Java? | int total = 22698; | ### Instruction:
Как объявить переменную total со значением 22698 в Java?
### Response:
int total = 22698; |
37,991,523 | 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;
} |
18,447,983 | en | Java | array_ops | advanced | Write a function that finds the maximum number in an array in Java. | 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 Java.
### Response:
public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} |
56,117,351 | 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] |
95,545,786 | en | Java | string_ops | advanced | 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;
} |
67,503,422 | en | Unity | array_ops | advanced | Write a function that reverses a list in Unity. | public void Reverse(int[] arr) {
System.Array.Reverse(arr);
} | ### Instruction:
Write a function that reverses a list in Unity.
### Response:
public void Reverse(int[] arr) {
System.Array.Reverse(arr);
} |
26,633,811 | en | Python | string_ops | intermediate | Write a function that counts vowels in a text in Python. | def count_vowels(s):
return sum(1 for c in s if c in 'aeiouAEIOUаеёиоуыэюя') | ### Instruction:
Write a function that counts vowels in a text in Python.
### Response:
def count_vowels(s):
return sum(1 for c in s if c in 'aeiouAEIOUаеёиоуыэюя') |
85,889,180 | ru | JavaScript | logic_ops | intermediate | Напишите на JavaScript функцию, определяющую, является ли число 269 простым. | function isPrime() {
let n = 269;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} | ### Instruction:
Напишите на JavaScript функцию, определяющую, является ли число 269 простым.
### Response:
function isPrime() {
let n = 269;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} |
133,922 | en | Unity | factorial | advanced | Write a function in Unity that calculates the factorial of 369. | long Factorial(int n) {
return n <= 1 ? 1 : n * Factorial(n - 1);
}
void Start() {
Debug.Log(Factorial(369));
} | ### Instruction:
Write a function in Unity that calculates the factorial of 369.
### Response:
long Factorial(int n) {
return n <= 1 ? 1 : n * Factorial(n - 1);
}
void Start() {
Debug.Log(Factorial(369));
} |
4,697,050 | en | C++ | var_decl | beginner | How to declare a variable value with value 2608 in C++? | int value = 2608; | ### Instruction:
How to declare a variable value with value 2608 in C++?
### Response:
int value = 2608; |
44,456,131 | 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();
} |
43,683,833 | kk | Python | logic_ops | advanced | Python тилінде 1922 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | def is_leap():
year = 1922
return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0) | ### Instruction:
Python тилінде 1922 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
def is_leap():
year = 1922
return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0) |
67,869,396 | 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;
} |
53,363,918 | kk | Unity | logic_ops | advanced | Unity тилінде 461 санының жай сан екенін анықтайтын функцияны жазыңыз. | public bool IsPrime() {
int n = 461;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
Unity тилінде 461 санының жай сан екенін анықтайтын функцияны жазыңыз.
### Response:
public bool IsPrime() {
int n = 461;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
41,872,309 | ru | 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;
} |
30,174,468 | 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] |
1,558,259 | kk | Unity | var_decl | beginner | Unity тілінде 673041 мәнімен level айнымалысын қалай жариялауға болады? | int level = 673041; | ### Instruction:
Unity тілінде 673041 мәнімен level айнымалысын қалай жариялауға болады?
### Response:
int level = 673041; |
1,795,034 | kk | Python | var_decl | beginner | Python тілінде 763649 мәнімен level айнымалысын қалай жариялауға болады? | level = 763649 | ### Instruction:
Python тілінде 763649 мәнімен level айнымалысын қалай жариялауға болады?
### Response:
level = 763649 |
2,164,190 | ru | C++ | var_decl | beginner | Как объявить переменную data со значением 214603 в C++? | int data = 214603; | ### Instruction:
Как объявить переменную data со значением 214603 в C++?
### Response:
int data = 214603; |
3,764,439 | kk | Python | var_decl | beginner | Python тілінде 4034 мәнімен offset айнымалысын қалай жариялауға болады? | offset = 4034 | ### Instruction:
Python тілінде 4034 мәнімен offset айнымалысын қалай жариялауға болады?
### Response:
offset = 4034 |
4,912,873 | ru | C++ | var_decl | beginner | Как объявить переменную rate со значением 51914 в C++? | int rate = 51914; | ### Instruction:
Как объявить переменную rate со значением 51914 в C++?
### Response:
int rate = 51914; |
70,970,504 | 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);
} |
79,844,783 | en | C++ | array_ops | intermediate | 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;
} |
62,180,689 | ru | C++ | logic_ops | advanced | Напишите на C++ функцию, определяющую, является ли число 453 простым. | public bool IsPrime() {
int n = 453;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
Напишите на C++ функцию, определяющую, является ли число 453 простым.
### Response:
public bool IsPrime() {
int n = 453;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
68,486,516 | 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;
} |
1,779,347 | ru | C++ | var_decl | beginner | Как объявить переменную limit со значением 37226 в C++? | int limit = 37226; | ### Instruction:
Как объявить переменную limit со значением 37226 в C++?
### Response:
int limit = 37226; |
34,388,750 | ru | 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;
} |
77,163,600 | 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;
} |
4,357,184 | kk | JavaScript | var_decl | beginner | JavaScript тілінде 417245 мәнімен timer айнымалысын қалай жариялауға болады? | let timer = 417245; | ### Instruction:
JavaScript тілінде 417245 мәнімен timer айнымалысын қалай жариялауға болады?
### Response:
let timer = 417245; |
79,171,166 | en | Unity | array_ops | advanced | Write a function that reverses a list in Unity. | public void Reverse(int[] arr) {
System.Array.Reverse(arr);
} | ### Instruction:
Write a function that reverses a list in Unity.
### Response:
public void Reverse(int[] arr) {
System.Array.Reverse(arr);
} |
3,637,375 | kk | Java | var_decl | beginner | Java тілінде 854442 мәнімен count айнымалысын қалай жариялауға болады? | int count = 854442; | ### Instruction:
Java тілінде 854442 мәнімен count айнымалысын қалай жариялауға болады?
### Response:
int count = 854442; |
52,022,507 | ru | C# | logic_ops | intermediate | Напишите на C# логику проверки, является ли год 2019 високосным. | public bool IsLeap() {
int y = 2019;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Напишите на C# логику проверки, является ли год 2019 високосным.
### Response:
public bool IsLeap() {
int y = 2019;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
45,335,861 | 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] |
566,443 | kk | JavaScript | var_decl | beginner | JavaScript тілінде 358930 мәнімен offset айнымалысын қалай жариялауға болады? | let offset = 358930; | ### Instruction:
JavaScript тілінде 358930 мәнімен offset айнымалысын қалай жариялауға болады?
### Response:
let offset = 358930; |
71,475,788 | kk | JavaScript | logic_ops | intermediate | JavaScript тилінде 62 санының жай сан екенін анықтайтын функцияны жазыңыз. | function isPrime() {
let n = 62;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} | ### Instruction:
JavaScript тилінде 62 санының жай сан екенін анықтайтын функцияны жазыңыз.
### Response:
function isPrime() {
let n = 62;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} |
3,447,937 | kk | Unity | var_decl | beginner | Unity тілінде 524544 мәнімен timer айнымалысын қалай жариялауға болады? | int timer = 524544; | ### Instruction:
Unity тілінде 524544 мәнімен timer айнымалысын қалай жариялауға болады?
### Response:
int timer = 524544; |
48,052 | ru | C# | func_def | intermediate | Напиши функцию generate в C#, которая принимает rate и удваивает его. | static int generate(int rate) {
return rate * 2;
} | ### Instruction:
Напиши функцию generate в C#, которая принимает rate и удваивает его.
### Response:
static int generate(int rate) {
return rate * 2;
} |
1,132,521 | en | C# | var_decl | beginner | How to declare a variable result with value 419616 in C#? | int result = 419616; | ### Instruction:
How to declare a variable result with value 419616 in C#?
### Response:
int result = 419616; |
4,489,096 | en | C++ | var_decl | beginner | How to declare a variable x with value 649085 in C++? | int x = 649085; | ### Instruction:
How to declare a variable x with value 649085 in C++?
### Response:
int x = 649085; |
2,406,042 | en | Python | var_decl | beginner | How to declare a variable weight with value 817932 in Python? | weight = 817932 | ### Instruction:
How to declare a variable weight with value 817932 in Python?
### Response:
weight = 817932 |
78,115,411 | 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] |
63,672,474 | 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();
} |
83,064,560 | kk | Python | array_ops | advanced | Python тилінде тізімді керісінше айналдыратын функцияны жазыңыз. | def reverse_list(arr):
return arr[::-1] | ### Instruction:
Python тилінде тізімді керісінше айналдыратын функцияны жазыңыз.
### Response:
def reverse_list(arr):
return arr[::-1] |
45,419,133 | ru | C++ | logic_ops | advanced | Напишите на C++ логику проверки, является ли год 1977 високосным. | public bool IsLeap() {
int y = 1977;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Напишите на C++ логику проверки, является ли год 1977 високосным.
### Response:
public bool IsLeap() {
int y = 1977;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
1,275,574 | ru | Python | var_decl | beginner | Как объявить переменную rate со значением 873008 в Python? | rate = 873008 | ### Instruction:
Как объявить переменную rate со значением 873008 в Python?
### Response:
rate = 873008 |
3,023,274 | kk | JavaScript | var_decl | beginner | JavaScript тілінде 130850 мәнімен health айнымалысын қалай жариялауға болады? | let health = 130850; | ### Instruction:
JavaScript тілінде 130850 мәнімен health айнымалысын қалай жариялауға болады?
### Response:
let health = 130850; |
413,538 | kk | Unity | sum_n | intermediate | Unity тілінде 1-ден 5058-ге дейінгі сандардың қосындысын есептейтін функция жаз. | int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
void Start() {
Debug.Log(SumToN(5058));
} | ### Instruction:
Unity тілінде 1-ден 5058-ге дейінгі сандардың қосындысын есептейтін функция жаз.
### Response:
int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
void Start() {
Debug.Log(SumToN(5058));
} |
59,610,673 | ru | Java | array_ops | advanced | Напишите на Java функцию, которая разворачивает список задом наперед. | public void Reverse(int[] arr) {
System.Array.Reverse(arr);
} | ### Instruction:
Напишите на Java функцию, которая разворачивает список задом наперед.
### Response:
public void Reverse(int[] arr) {
System.Array.Reverse(arr);
} |
1,152,362 | kk | Java | var_decl | beginner | Java тілінде 58270 мәнімен y айнымалысын қалай жариялауға болады? | int y = 58270; | ### Instruction:
Java тілінде 58270 мәнімен y айнымалысын қалай жариялауға болады?
### Response:
int y = 58270; |
79,266,728 | en | JavaScript | logic_ops | intermediate | Write a function that determines if the number 52 is prime in JavaScript. | function isPrime() {
let n = 52;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} | ### Instruction:
Write a function that determines if the number 52 is prime in JavaScript.
### Response:
function isPrime() {
let n = 52;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} |
17,407,728 | ru | Java | string_ops | advanced | Напишите на 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,488,938 | en | JavaScript | var_decl | beginner | How to declare a variable value with value 791938 in JavaScript? | let value = 791938; | ### Instruction:
How to declare a variable value with value 791938 in JavaScript?
### Response:
let value = 791938; |
15,014,169 | en | Java | logic_ops | intermediate | Write a function that determines if the number 127 is prime in Java. | public bool IsPrime() {
int n = 127;
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 127 is prime in Java.
### Response:
public bool IsPrime() {
int n = 127;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
4,402,886 | ru | Python | var_decl | beginner | Как объявить переменную score со значением 971727 в Python? | score = 971727 | ### Instruction:
Как объявить переменную score со значением 971727 в Python?
### Response:
score = 971727 |
89,051,666 | 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] |
4,703,139 | en | Java | var_decl | beginner | How to declare a variable size with value 543069 in Java? | int size = 543069; | ### Instruction:
How to declare a variable size with value 543069 in Java?
### Response:
int size = 543069; |
87,468,402 | ru | C++ | logic_ops | intermediate | Напишите на C++ функцию, определяющую, является ли число 214 простым. | public bool IsPrime() {
int n = 214;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
Напишите на C++ функцию, определяющую, является ли число 214 простым.
### Response:
public bool IsPrime() {
int n = 214;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
3,885,040 | en | C# | var_decl | beginner | How to declare a variable amount with value 355845 in C#? | int amount = 355845; | ### Instruction:
How to declare a variable amount with value 355845 in C#?
### Response:
int amount = 355845; |
25,958,389 | en | Unity | logic_ops | advanced | Write a function that determines if the number 475 is prime in Unity. | public bool IsPrime() {
int n = 475;
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 475 is prime in Unity.
### Response:
public bool IsPrime() {
int n = 475;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
441,153 | ru | Unity | sum_n | intermediate | Напиши функцию на Unity, которая считает сумму чисел от 1 до 9994. | int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
void Start() {
Debug.Log(SumToN(9994));
} | ### Instruction:
Напиши функцию на Unity, которая считает сумму чисел от 1 до 9994.
### Response:
int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
void Start() {
Debug.Log(SumToN(9994));
} |
75,966,735 | kk | JavaScript | array_ops | advanced | JavaScript тилінде жиымдағы ең үлкен санды табатын функцияны жазыңыз. | const getMax = arr => Math.max(...arr); | ### Instruction:
JavaScript тилінде жиымдағы ең үлкен санды табатын функцияны жазыңыз.
### Response:
const getMax = arr => Math.max(...arr); |
17,471,481 | kk | JavaScript | array_ops | advanced | JavaScript тилінде тізімнен тек жұп сандарды сүзетін функцияны жазыңыз. | const filterEven = arr => arr.filter(x => x % 2 === 0); | ### Instruction:
JavaScript тилінде тізімнен тек жұп сандарды сүзетін функцияны жазыңыз.
### Response:
const filterEven = arr => arr.filter(x => x % 2 === 0); |
4,238,520 | en | Unity | var_decl | beginner | How to declare a variable amount with value 157496 in Unity? | int amount = 157496; | ### Instruction:
How to declare a variable amount with value 157496 in Unity?
### Response:
int amount = 157496; |
43,986,241 | ru | Python | array_ops | advanced | Напишите на 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] |
2,143,313 | ru | Java | var_decl | beginner | Как объявить переменную size со значением 152038 в Java? | int size = 152038; | ### Instruction:
Как объявить переменную size со значением 152038 в Java?
### Response:
int size = 152038; |
1,459,576 | kk | Python | var_decl | beginner | Python тілінде 59575 мәнімен x айнымалысын қалай жариялауға болады? | x = 59575 | ### Instruction:
Python тілінде 59575 мәнімен x айнымалысын қалай жариялауға болады?
### Response:
x = 59575 |
3,978,952 | ru | C# | var_decl | beginner | Как объявить переменную result со значением 200859 в C#? | int result = 200859; | ### Instruction:
Как объявить переменную result со значением 200859 в C#?
### Response:
int result = 200859; |
2,659,422 | en | Unity | var_decl | beginner | How to declare a variable size with value 415333 in Unity? | int size = 415333; | ### Instruction:
How to declare a variable size with value 415333 in Unity?
### Response:
int size = 415333; |
24,564,330 | 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();
} |
47,927,482 | en | C# | array_ops | intermediate | 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;
} |
1,232,076 | ru | Java | var_decl | beginner | Как объявить переменную count со значением 36628 в Java? | int count = 36628; | ### Instruction:
Как объявить переменную count со значением 36628 в Java?
### Response:
int count = 36628; |
43,341,664 | en | Unity | logic_ops | advanced | Write logic to check if the year 2015 is a leap year in Unity. | public bool IsLeap() {
int y = 2015;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Write logic to check if the year 2015 is a leap year in Unity.
### Response:
public bool IsLeap() {
int y = 2015;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
4,783,067 | kk | JavaScript | var_decl | beginner | JavaScript тілінде 439244 мәнімен index айнымалысын қалай жариялауға болады? | let index = 439244; | ### Instruction:
JavaScript тілінде 439244 мәнімен index айнымалысын қалай жариялауға болады?
### Response:
let index = 439244; |
81,050,838 | ru | 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;
} |
13,116,280 | 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;
} |
28,109,959 | kk | 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);
} |
2,399,980 | en | C++ | var_decl | beginner | How to declare a variable x with value 234825 in C++? | int x = 234825; | ### Instruction:
How to declare a variable x with value 234825 in C++?
### Response:
int x = 234825; |
70,680,906 | 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;
} |
3,413,508 | ru | JavaScript | var_decl | beginner | Как объявить переменную data со значением 682519 в JavaScript? | let data = 682519; | ### Instruction:
Как объявить переменную data со значением 682519 в JavaScript?
### Response:
let data = 682519; |
13,195,662 | kk | Python | logic_ops | advanced | Python тилінде 1992 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | def is_leap():
year = 1992
return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0) | ### Instruction:
Python тилінде 1992 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
def is_leap():
year = 1992
return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0) |
29,170,413 | en | C# | array_ops | advanced | 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);
} |
58,925,022 | ru | Python | string_ops | advanced | Напишите на Python функцию, которая проверяет, является ли строка палиндромом. | def is_palindrome(s):
return s == s[::-1] | ### Instruction:
Напишите на Python функцию, которая проверяет, является ли строка палиндромом.
### Response:
def is_palindrome(s):
return s == s[::-1] |
37,797,168 | ru | Unity | logic_ops | intermediate | Напишите на Unity функцию, определяющую, является ли число 259 простым. | public bool IsPrime() {
int n = 259;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
Напишите на Unity функцию, определяющую, является ли число 259 простым.
### Response:
public bool IsPrime() {
int n = 259;
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.