id int64 | language string | prog_lang string | category string | difficulty string | instruction string | output string | text string |
|---|---|---|---|---|---|---|---|
90,767,724 | 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;
} |
92,887,560 | 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); |
19,461,149 | 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,026,406 | kk | C++ | var_decl | beginner | C++ тілінде 827326 мәнімен buffer айнымалысын қалай жариялауға болады? | int buffer = 827326; | ### Instruction:
C++ тілінде 827326 мәнімен buffer айнымалысын қалай жариялауға болады?
### Response:
int buffer = 827326; |
81,794,846 | 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;
} |
4,761,998 | ru | JavaScript | var_decl | beginner | Как объявить переменную buffer со значением 902950 в JavaScript? | let buffer = 902950; | ### Instruction:
Как объявить переменную buffer со значением 902950 в JavaScript?
### Response:
let buffer = 902950; |
2,062,280 | ru | JavaScript | var_decl | beginner | Как объявить переменную weight со значением 67160 в JavaScript? | let weight = 67160; | ### Instruction:
Как объявить переменную weight со значением 67160 в JavaScript?
### Response:
let weight = 67160; |
81,984,011 | 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;
} |
95,811,718 | ru | C++ | logic_ops | advanced | Напишите на C++ логику проверки, является ли год 1912 високосным. | public bool IsLeap() {
int y = 1912;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Напишите на C++ логику проверки, является ли год 1912 високосным.
### Response:
public bool IsLeap() {
int y = 1912;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
10,224,557 | 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;
} |
2,563,458 | ru | Java | var_decl | beginner | Как объявить переменную value со значением 786639 в Java? | int value = 786639; | ### Instruction:
Как объявить переменную value со значением 786639 в Java?
### Response:
int value = 786639; |
28,075,086 | 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;
} |
1,082,178 | kk | Unity | var_decl | beginner | Unity тілінде 884212 мәнімен index айнымалысын қалай жариялауға болады? | int index = 884212; | ### Instruction:
Unity тілінде 884212 мәнімен index айнымалысын қалай жариялауға болады?
### Response:
int index = 884212; |
74,723,150 | ru | Python | string_ops | intermediate | Напишите на Python функцию, которая проверяет, является ли строка палиндромом. | def is_palindrome(s):
return s == s[::-1] | ### Instruction:
Напишите на Python функцию, которая проверяет, является ли строка палиндромом.
### Response:
def is_palindrome(s):
return s == s[::-1] |
1,164,742 | en | C# | var_decl | beginner | How to declare a variable x with value 888520 in C#? | int x = 888520; | ### Instruction:
How to declare a variable x with value 888520 in C#?
### Response:
int x = 888520; |
2,663,390 | kk | Python | var_decl | beginner | Python тілінде 781529 мәнімен amount айнымалысын қалай жариялауға болады? | amount = 781529 | ### Instruction:
Python тілінде 781529 мәнімен amount айнымалысын қалай жариялауға болады?
### Response:
amount = 781529 |
47,546,746 | kk | 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;
} |
40,096,574 | en | JavaScript | array_ops | advanced | 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); |
54,953 | kk | Java | sum_n | intermediate | Java тілінде 1-ден 2120-ге дейінгі сандардың қосындысын есептейтін функция жаз. | static int sumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
System.out.println(sumToN(2120)); | ### Instruction:
Java тілінде 1-ден 2120-ге дейінгі сандардың қосындысын есептейтін функция жаз.
### Response:
static int sumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
System.out.println(sumToN(2120)); |
16,937,003 | 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] |
4,221,548 | kk | C++ | var_decl | beginner | C++ тілінде 383102 мәнімен speed айнымалысын қалай жариялауға болады? | int speed = 383102; | ### Instruction:
C++ тілінде 383102 мәнімен speed айнымалысын қалай жариялауға болады?
### Response:
int speed = 383102; |
276,512 | ru | Java | factorial | advanced | Напиши функцию на Java, которая вычисляет факториал числа 1842. | static long factorial(int n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
System.out.println(factorial(1842)); | ### Instruction:
Напиши функцию на Java, которая вычисляет факториал числа 1842.
### Response:
static long factorial(int n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
System.out.println(factorial(1842)); |
1,079,340 | kk | Python | var_decl | beginner | Python тілінде 496664 мәнімен speed айнымалысын қалай жариялауға болады? | speed = 496664 | ### Instruction:
Python тілінде 496664 мәнімен speed айнымалысын қалай жариялауға болады?
### Response:
speed = 496664 |
4,370,699 | en | Java | var_decl | beginner | How to declare a variable total with value 644104 in Java? | int total = 644104; | ### Instruction:
How to declare a variable total with value 644104 in Java?
### Response:
int total = 644104; |
58,391,809 | ru | 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;
} |
3,189,478 | kk | Java | var_decl | beginner | Java тілінде 264691 мәнімен value айнымалысын қалай жариялауға болады? | int value = 264691; | ### Instruction:
Java тілінде 264691 мәнімен value айнымалысын қалай жариялауға болады?
### Response:
int value = 264691; |
27,996,099 | 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;
} |
44,277,390 | kk | C++ | logic_ops | intermediate | C++ тилінде 498 санының жай сан екенін анықтайтын функцияны жазыңыз. | public bool IsPrime() {
int n = 498;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
C++ тилінде 498 санының жай сан екенін анықтайтын функцияны жазыңыз.
### Response:
public bool IsPrime() {
int n = 498;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
95,322,031 | 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();
} |
49,542,871 | 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,434,194 | kk | C# | var_decl | beginner | C# тілінде 62131 мәнімен y айнымалысын қалай жариялауға болады? | int y = 62131; | ### Instruction:
C# тілінде 62131 мәнімен y айнымалысын қалай жариялауға болады?
### Response:
int y = 62131; |
19,334,713 | 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);
} |
4,965,900 | en | Java | var_decl | beginner | How to declare a variable index with value 926041 in Java? | int index = 926041; | ### Instruction:
How to declare a variable index with value 926041 in Java?
### Response:
int index = 926041; |
67,714,218 | kk | C# | logic_ops | advanced | C# тилінде 2050 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | public bool IsLeap() {
int y = 2050;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
C# тилінде 2050 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
public bool IsLeap() {
int y = 2050;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
2,400,254 | kk | JavaScript | var_decl | beginner | JavaScript тілінде 234525 мәнімен amount айнымалысын қалай жариялауға болады? | let amount = 234525; | ### Instruction:
JavaScript тілінде 234525 мәнімен amount айнымалысын қалай жариялауға болады?
### Response:
let amount = 234525; |
94,007,449 | kk | Python | string_ops | advanced | Python тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз. | def to_upper(s):
return s.upper() | ### Instruction:
Python тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз.
### Response:
def to_upper(s):
return s.upper() |
87,896,057 | ru | C# | logic_ops | advanced | Напишите на C# функцию, определяющую, является ли число 159 простым. | public bool IsPrime() {
int n = 159;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
Напишите на C# функцию, определяющую, является ли число 159 простым.
### Response:
public bool IsPrime() {
int n = 159;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
71,665,865 | ru | JavaScript | logic_ops | intermediate | Напишите на JavaScript функцию, определяющую, является ли число 16 простым. | function isPrime() {
let n = 16;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} | ### Instruction:
Напишите на JavaScript функцию, определяющую, является ли число 16 простым.
### Response:
function isPrime() {
let n = 16;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} |
217,028 | en | C++ | var_decl | beginner | How to declare a variable count with value 14961 in C++? | int count = 14961; | ### Instruction:
How to declare a variable count with value 14961 in C++?
### Response:
int count = 14961; |
94,226,200 | kk | C# | logic_ops | intermediate | C# тилінде 1914 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | public bool IsLeap() {
int y = 1914;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
C# тилінде 1914 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
public bool IsLeap() {
int y = 1914;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
40,129,453 | ru | JavaScript | array_ops | advanced | Напишите на JavaScript функцию, которая разворачивает список задом наперед. | const reverseArr = arr => arr.reverse(); | ### Instruction:
Напишите на JavaScript функцию, которая разворачивает список задом наперед.
### Response:
const reverseArr = arr => arr.reverse(); |
89,964,061 | en | Python | string_ops | advanced | 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аеёиоуыэюя') |
13,574,193 | 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;
} |
3,380,200 | en | Unity | var_decl | beginner | How to declare a variable count with value 13002 in Unity? | int count = 13002; | ### Instruction:
How to declare a variable count with value 13002 in Unity?
### Response:
int count = 13002; |
41,999 | kk | JavaScript | factorial | advanced | JavaScript тілінде 5899 санының факториалын есептейтін функция жаз. | function factorial(n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
console.log(factorial(5899)); | ### Instruction:
JavaScript тілінде 5899 санының факториалын есептейтін функция жаз.
### Response:
function factorial(n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
console.log(factorial(5899)); |
51,599,369 | en | C# | string_ops | advanced | Write a function that counts vowels in a text in C#. | public int CountVowels(string s) {
int c = 0;
foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++;
return c;
} | ### Instruction:
Write a function that counts vowels in a text in C#.
### Response:
public int CountVowels(string s) {
int c = 0;
foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++;
return c;
} |
65,744,541 | ru | Python | logic_ops | advanced | Напишите на Python логику проверки, является ли год 1970 високосным. | def is_leap():
year = 1970
return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0) | ### Instruction:
Напишите на Python логику проверки, является ли год 1970 високосным.
### Response:
def is_leap():
year = 1970
return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0) |
53,657,989 | en | JavaScript | logic_ops | intermediate | Write a function that determines if the number 337 is prime in JavaScript. | function isPrime() {
let n = 337;
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 337 is prime in JavaScript.
### Response:
function isPrime() {
let n = 337;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} |
73,542,666 | kk | Java | logic_ops | intermediate | Java тилінде 135 санының жай сан екенін анықтайтын функцияны жазыңыз. | public bool IsPrime() {
int n = 135;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
Java тилінде 135 санының жай сан екенін анықтайтын функцияны жазыңыз.
### Response:
public bool IsPrime() {
int n = 135;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
96,494,273 | 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();
} |
80,991,415 | kk | JavaScript | array_ops | intermediate | JavaScript тилінде жиымдағы ең үлкен санды табатын функцияны жазыңыз. | const getMax = arr => Math.max(...arr); | ### Instruction:
JavaScript тилінде жиымдағы ең үлкен санды табатын функцияны жазыңыз.
### Response:
const getMax = arr => Math.max(...arr); |
14,584,151 | 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);
} |
34,044,680 | ru | C++ | logic_ops | intermediate | Напишите на C++ логику проверки, является ли год 1970 високосным. | public bool IsLeap() {
int y = 1970;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Напишите на C++ логику проверки, является ли год 1970 високосным.
### Response:
public bool IsLeap() {
int y = 1970;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
33,130,958 | 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] |
3,283,919 | en | C# | var_decl | beginner | How to declare a variable data with value 143249 in C#? | int data = 143249; | ### Instruction:
How to declare a variable data with value 143249 in C#?
### Response:
int data = 143249; |
76,825,095 | ru | Java | array_ops | advanced | Напишите на 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;
} |
4,496,856 | en | C# | var_decl | beginner | How to declare a variable value with value 324587 in C#? | int value = 324587; | ### Instruction:
How to declare a variable value with value 324587 in C#?
### Response:
int value = 324587; |
32,050,836 | kk | C++ | logic_ops | advanced | C++ тилінде 2096 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | public bool IsLeap() {
int y = 2096;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
C++ тилінде 2096 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
public bool IsLeap() {
int y = 2096;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
45,237,532 | 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;
} |
84,583,399 | 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();
} |
44,626,895 | ru | C# | logic_ops | intermediate | Напишите на C# функцию, определяющую, является ли число 489 простым. | public bool IsPrime() {
int n = 489;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
Напишите на C# функцию, определяющую, является ли число 489 простым.
### Response:
public bool IsPrime() {
int n = 489;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
2,664,710 | en | Unity | var_decl | beginner | How to declare a variable offset with value 166762 in Unity? | int offset = 166762; | ### Instruction:
How to declare a variable offset with value 166762 in Unity?
### Response:
int offset = 166762; |
3,671,563 | en | Java | var_decl | beginner | How to declare a variable score with value 898678 in Java? | int score = 898678; | ### Instruction:
How to declare a variable score with value 898678 in Java?
### Response:
int score = 898678; |
4,431,831 | ru | C# | var_decl | beginner | Как объявить переменную weight со значением 883153 в C#? | int weight = 883153; | ### Instruction:
Как объявить переменную weight со значением 883153 в C#?
### Response:
int weight = 883153; |
2,478,514 | ru | C# | var_decl | beginner | Как объявить переменную value со значением 55597 в C#? | int value = 55597; | ### Instruction:
Как объявить переменную value со значением 55597 в C#?
### Response:
int value = 55597; |
1,423,893 | en | C# | var_decl | beginner | How to declare a variable value with value 442376 in C#? | int value = 442376; | ### Instruction:
How to declare a variable value with value 442376 in C#?
### Response:
int value = 442376; |
53,850,764 | ru | C# | logic_ops | advanced | Напишите на C# функцию, определяющую, является ли число 415 простым. | public bool IsPrime() {
int n = 415;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
Напишите на C# функцию, определяющую, является ли число 415 простым.
### Response:
public bool IsPrime() {
int n = 415;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
1,604,082 | en | JavaScript | var_decl | beginner | How to declare a variable count with value 690950 in JavaScript? | let count = 690950; | ### Instruction:
How to declare a variable count with value 690950 in JavaScript?
### Response:
let count = 690950; |
57,916,266 | en | C# | string_ops | intermediate | 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;
} |
21,152,831 | ru | C++ | logic_ops | advanced | Напишите на C++ логику проверки, является ли год 2042 високосным. | public bool IsLeap() {
int y = 2042;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Напишите на C++ логику проверки, является ли год 2042 високосным.
### Response:
public bool IsLeap() {
int y = 2042;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
831,257 | ru | Java | var_decl | beginner | Как объявить переменную score со значением 227337 в Java? | int score = 227337; | ### Instruction:
Как объявить переменную score со значением 227337 в Java?
### Response:
int score = 227337; |
1,025,293 | en | Unity | var_decl | beginner | How to declare a variable total with value 335417 in Unity? | int total = 335417; | ### Instruction:
How to declare a variable total with value 335417 in Unity?
### Response:
int total = 335417; |
44,981,717 | 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;
} |
89,788,190 | kk | C# | logic_ops | advanced | C# тилінде 2069 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | public bool IsLeap() {
int y = 2069;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
C# тилінде 2069 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
public bool IsLeap() {
int y = 2069;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
187,146 | en | Java | factorial | advanced | Write a function in Java that calculates the factorial of 5578. | static long factorial(int n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
System.out.println(factorial(5578)); | ### Instruction:
Write a function in Java that calculates the factorial of 5578.
### Response:
static long factorial(int n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
System.out.println(factorial(5578)); |
85,210,548 | en | Unity | logic_ops | advanced | Write logic to check if the year 1991 is a leap year in Unity. | public bool IsLeap() {
int y = 1991;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Write logic to check if the year 1991 is a leap year in Unity.
### Response:
public bool IsLeap() {
int y = 1991;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
96,451,820 | kk | Unity | array_ops | intermediate | 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;
} |
22,448,695 | 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);
} |
23,006,531 | ru | C++ | logic_ops | advanced | Напишите на C++ функцию, определяющую, является ли число 402 простым. | public bool IsPrime() {
int n = 402;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
Напишите на C++ функцию, определяющую, является ли число 402 простым.
### Response:
public bool IsPrime() {
int n = 402;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
87,803,803 | 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;
} |
36,882,916 | 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;
} |
4,865,955 | en | Unity | var_decl | beginner | How to declare a variable limit with value 365137 in Unity? | int limit = 365137; | ### Instruction:
How to declare a variable limit with value 365137 in Unity?
### Response:
int limit = 365137; |
1,295,818 | en | Java | var_decl | beginner | How to declare a variable buffer with value 788105 in Java? | int buffer = 788105; | ### Instruction:
How to declare a variable buffer with value 788105 in Java?
### Response:
int buffer = 788105; |
4,375,539 | kk | Java | var_decl | beginner | Java тілінде 189831 мәнімен timer айнымалысын қалай жариялауға болады? | int timer = 189831; | ### Instruction:
Java тілінде 189831 мәнімен timer айнымалысын қалай жариялауға болады?
### Response:
int timer = 189831; |
196,590 | kk | C# | sum_n | intermediate | C# тілінде 1-ден 2926-ге дейінгі сандардың қосындысын есептейтін функция жаз. | static int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
Console.WriteLine(SumToN(2926)); | ### Instruction:
C# тілінде 1-ден 2926-ге дейінгі сандардың қосындысын есептейтін функция жаз.
### Response:
static int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
Console.WriteLine(SumToN(2926)); |
165,409 | en | C# | var_decl | beginner | How to declare a variable buffer with value 157312 in C#? | int buffer = 157312; | ### Instruction:
How to declare a variable buffer with value 157312 in C#?
### Response:
int buffer = 157312; |
48,057,408 | 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;
} |
10,832,824 | kk | Python | array_ops | intermediate | Python тилінде жиымдағы ең үлкен санды табатын функцияны жазыңыз. | def get_max(arr):
return max(arr) | ### Instruction:
Python тилінде жиымдағы ең үлкен санды табатын функцияны жазыңыз.
### Response:
def get_max(arr):
return max(arr) |
48,475,553 | en | JavaScript | logic_ops | advanced | Write logic to check if the year 1914 is a leap year in JavaScript. | function isLeap() {
let y = 1914;
return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0);
} | ### Instruction:
Write logic to check if the year 1914 is a leap year in JavaScript.
### Response:
function isLeap() {
let y = 1914;
return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0);
} |
67,658,357 | 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;
} |
1,306,374 | en | Unity | var_decl | beginner | How to declare a variable buffer with value 394864 in Unity? | int buffer = 394864; | ### Instruction:
How to declare a variable buffer with value 394864 in Unity?
### Response:
int buffer = 394864; |
64,878,911 | kk | JavaScript | string_ops | advanced | JavaScript тилінде жолдың палиндром екенін тексеретін функцияны жазыңыз. | const isPalindrome = s => s === s.split('').reverse().join(''); | ### Instruction:
JavaScript тилінде жолдың палиндром екенін тексеретін функцияны жазыңыз.
### Response:
const isPalindrome = s => s === s.split('').reverse().join(''); |
62,401,884 | 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;
} |
50,919,258 | en | Unity | array_ops | intermediate | 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);
} |
66,703,012 | 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;
} |
2,239,219 | ru | C# | var_decl | beginner | Как объявить переменную count со значением 199514 в C#? | int count = 199514; | ### Instruction:
Как объявить переменную count со значением 199514 в C#?
### Response:
int count = 199514; |
1,234,692 | en | C++ | factorial | advanced | Write a function in C++ that calculates the factorial of 456. | long long factorial(int n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
std::cout << factorial(456) << std::endl; | ### Instruction:
Write a function in C++ that calculates the factorial of 456.
### Response:
long long factorial(int n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
std::cout << factorial(456) << std::endl; |
88,505,007 | 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аеёиоуыэюя') |
93,846,749 | en | Java | logic_ops | advanced | Write logic to check if the year 1985 is a leap year in Java. | public bool IsLeap() {
int y = 1985;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Write logic to check if the year 1985 is a leap year in Java.
### Response:
public bool IsLeap() {
int y = 1985;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
52,107,521 | 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;
} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.