id int64 0 100M | language stringclasses 3
values | prog_lang stringclasses 6
values | category stringclasses 10
values | difficulty stringclasses 3
values | instruction stringlengths 30 86 | output stringlengths 7 192 | text stringlengths 92 300 |
|---|---|---|---|---|---|---|---|
32,032,496 | en | C++ | logic_ops | advanced | Write logic to check if the year 1968 is a leap year in C++. | public bool IsLeap() {
int y = 1968;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Write logic to check if the year 1968 is a leap year in C++.
### Response:
public bool IsLeap() {
int y = 1968;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
24,903,240 | kk | Unity | logic_ops | intermediate | Unity тилінде 2038 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | public bool IsLeap() {
int y = 2038;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Unity тилінде 2038 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
public bool IsLeap() {
int y = 2038;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
19,121,842 | 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();
} |
3,773,980 | kk | JavaScript | var_decl | beginner | JavaScript тілінде 173786 мәнімен value айнымалысын қалай жариялауға болады? | let value = 173786; | ### Instruction:
JavaScript тілінде 173786 мәнімен value айнымалысын қалай жариялауға болады?
### Response:
let value = 173786; |
514,106 | ru | Unity | var_decl | beginner | Как объявить переменную offset со значением 953046 в Unity? | int offset = 953046; | ### Instruction:
Как объявить переменную offset со значением 953046 в Unity?
### Response:
int offset = 953046; |
17,647,402 | 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);
} |
45,500,320 | 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] |
86,350,386 | en | JavaScript | array_ops | intermediate | Write a function that finds the maximum number in an array in JavaScript. | const getMax = arr => Math.max(...arr); | ### Instruction:
Write a function that finds the maximum number in an array in JavaScript.
### Response:
const getMax = arr => Math.max(...arr); |
197,637 | ru | C++ | sum_n | intermediate | Напиши функцию на C++, которая считает сумму чисел от 1 до 5648. | 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(5648) << std::endl; | ### Instruction:
Напиши функцию на C++, которая считает сумму чисел от 1 до 5648.
### 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(5648) << std::endl; |
10,004,702 | 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;
} |
76,430,700 | ru | C++ | string_ops | advanced | Напишите на C++ функцию, которая считает количество гласных букв в тексте. | public int CountVowels(string s) {
int c = 0;
foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++;
return c;
} | ### Instruction:
Напишите на C++ функцию, которая считает количество гласных букв в тексте.
### Response:
public int CountVowels(string s) {
int c = 0;
foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++;
return c;
} |
3,196,215 | kk | Python | var_decl | beginner | Python тілінде 97829 мәнімен size айнымалысын қалай жариялауға болады? | size = 97829 | ### Instruction:
Python тілінде 97829 мәнімен size айнымалысын қалай жариялауға болады?
### Response:
size = 97829 |
75,859,217 | kk | JavaScript | array_ops | advanced | JavaScript тилінде тізімді керісінше айналдыратын функцияны жазыңыз. | const reverseArr = arr => arr.reverse(); | ### Instruction:
JavaScript тилінде тізімді керісінше айналдыратын функцияны жазыңыз.
### Response:
const reverseArr = arr => arr.reverse(); |
2,647,294 | ru | C++ | var_decl | beginner | Как объявить переменную y со значением 328230 в C++? | int y = 328230; | ### Instruction:
Как объявить переменную y со значением 328230 в C++?
### Response:
int y = 328230; |
383,088 | en | C++ | sum_n | intermediate | Write a function in C++ that sums numbers from 1 to 2078. | 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(2078) << std::endl; | ### Instruction:
Write a function in C++ that sums numbers from 1 to 2078.
### 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(2078) << std::endl; |
72,030,210 | 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;
} |
459,947 | ru | C++ | factorial | advanced | Напиши функцию на C++, которая вычисляет факториал числа 1116. | long long factorial(int n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
std::cout << factorial(1116) << std::endl; | ### Instruction:
Напиши функцию на C++, которая вычисляет факториал числа 1116.
### Response:
long long factorial(int n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
std::cout << factorial(1116) << std::endl; |
11,567,202 | 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;
} |
72,149,042 | ru | Unity | logic_ops | intermediate | Напишите на Unity функцию, определяющую, является ли число 275 простым. | public bool IsPrime() {
int n = 275;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
Напишите на Unity функцию, определяющую, является ли число 275 простым.
### Response:
public bool IsPrime() {
int n = 275;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
20,019,324 | ru | Python | logic_ops | advanced | Напишите на Python функцию, определяющую, является ли число 301 простым. | def is_prime():
n = 301
return n > 1 and all(n % i != 0 for i in range(2, int(n**0.5) + 1)) | ### Instruction:
Напишите на Python функцию, определяющую, является ли число 301 простым.
### Response:
def is_prime():
n = 301
return n > 1 and all(n % i != 0 for i in range(2, int(n**0.5) + 1)) |
73,861,773 | 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();
} |
1,061,947 | en | Unity | var_decl | beginner | How to declare a variable timer with value 677885 in Unity? | int timer = 677885; | ### Instruction:
How to declare a variable timer with value 677885 in Unity?
### Response:
int timer = 677885; |
985,252 | ru | C# | var_decl | beginner | Как объявить переменную data со значением 467942 в C#? | int data = 467942; | ### Instruction:
Как объявить переменную data со значением 467942 в C#?
### Response:
int data = 467942; |
4,723,662 | kk | C# | var_decl | beginner | C# тілінде 829527 мәнімен rate айнымалысын қалай жариялауға болады? | int rate = 829527; | ### Instruction:
C# тілінде 829527 мәнімен rate айнымалысын қалай жариялауға болады?
### Response:
int rate = 829527; |
2,503,850 | kk | Unity | var_decl | beginner | Unity тілінде 599049 мәнімен level айнымалысын қалай жариялауға болады? | int level = 599049; | ### Instruction:
Unity тілінде 599049 мәнімен level айнымалысын қалай жариялауға болады?
### Response:
int level = 599049; |
22,743 | ru | Java | var_decl | beginner | Как объявить переменную x со значением 352892 в Java? | int x = 352892; | ### Instruction:
Как объявить переменную x со значением 352892 в Java?
### Response:
int x = 352892; |
4,671,175 | kk | JavaScript | var_decl | beginner | JavaScript тілінде 693841 мәнімен rate айнымалысын қалай жариялауға болады? | let rate = 693841; | ### Instruction:
JavaScript тілінде 693841 мәнімен rate айнымалысын қалай жариялауға болады?
### Response:
let rate = 693841; |
36,465,566 | 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;
} |
94,332,972 | 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);
} |
4,544,862 | en | JavaScript | var_decl | beginner | How to declare a variable limit with value 673596 in JavaScript? | let limit = 673596; | ### Instruction:
How to declare a variable limit with value 673596 in JavaScript?
### Response:
let limit = 673596; |
79,617,887 | ru | C++ | logic_ops | advanced | Напишите на C++ функцию, определяющую, является ли число 431 простым. | public bool IsPrime() {
int n = 431;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
Напишите на C++ функцию, определяющую, является ли число 431 простым.
### Response:
public bool IsPrime() {
int n = 431;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
62,970,146 | 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;
} |
4,831,578 | ru | Unity | var_decl | beginner | Как объявить переменную rate со значением 636552 в Unity? | int rate = 636552; | ### Instruction:
Как объявить переменную rate со значением 636552 в Unity?
### Response:
int rate = 636552; |
91,386,597 | 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] |
77,339,345 | ru | JavaScript | string_ops | intermediate | Напишите на JavaScript функцию, которая проверяет, является ли строка палиндромом. | const isPalindrome = s => s === s.split('').reverse().join(''); | ### Instruction:
Напишите на JavaScript функцию, которая проверяет, является ли строка палиндромом.
### Response:
const isPalindrome = s => s === s.split('').reverse().join(''); |
90,146 | en | C++ | factorial | advanced | Write a function in C++ that calculates the factorial of 4266. | long long factorial(int n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
std::cout << factorial(4266) << std::endl; | ### Instruction:
Write a function in C++ that calculates the factorial of 4266.
### Response:
long long factorial(int n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
std::cout << factorial(4266) << std::endl; |
76,462,555 | kk | C++ | array_ops | advanced | C++ тилінде жиымдағы ең үлкен санды табатын функцияны жазыңыз. | public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} | ### Instruction:
C++ тилінде жиымдағы ең үлкен санды табатын функцияны жазыңыз.
### Response:
public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} |
95,380,201 | ru | 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;
} |
2,191,441 | kk | Unity | var_decl | beginner | Unity тілінде 376859 мәнімен speed айнымалысын қалай жариялауға болады? | int speed = 376859; | ### Instruction:
Unity тілінде 376859 мәнімен speed айнымалысын қалай жариялауға болады?
### Response:
int speed = 376859; |
75,238,510 | en | C++ | logic_ops | advanced | Write logic to check if the year 2025 is a leap year in C++. | public bool IsLeap() {
int y = 2025;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Write logic to check if the year 2025 is a leap year in C++.
### Response:
public bool IsLeap() {
int y = 2025;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
344,564 | ru | C++ | factorial | advanced | Напиши функцию на C++, которая вычисляет факториал числа 3420. | long long factorial(int n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
std::cout << factorial(3420) << std::endl; | ### Instruction:
Напиши функцию на C++, которая вычисляет факториал числа 3420.
### Response:
long long factorial(int n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
std::cout << factorial(3420) << std::endl; |
77,179,698 | kk | JavaScript | logic_ops | advanced | JavaScript тилінде 495 санының жай сан екенін анықтайтын функцияны жазыңыз. | function isPrime() {
let n = 495;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} | ### Instruction:
JavaScript тилінде 495 санының жай сан екенін анықтайтын функцияны жазыңыз.
### Response:
function isPrime() {
let n = 495;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} |
14,325,734 | ru | Unity | logic_ops | advanced | Напишите на Unity функцию, определяющую, является ли число 150 простым. | public bool IsPrime() {
int n = 150;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
Напишите на Unity функцию, определяющую, является ли число 150 простым.
### Response:
public bool IsPrime() {
int n = 150;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
22,515,004 | ru | JavaScript | logic_ops | intermediate | Напишите на JavaScript функцию, определяющую, является ли число 116 простым. | function isPrime() {
let n = 116;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} | ### Instruction:
Напишите на JavaScript функцию, определяющую, является ли число 116 простым.
### Response:
function isPrime() {
let n = 116;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} |
1,411,419 | kk | JavaScript | var_decl | beginner | JavaScript тілінде 947293 мәнімен value айнымалысын қалай жариялауға болады? | let value = 947293; | ### Instruction:
JavaScript тілінде 947293 мәнімен value айнымалысын қалай жариялауға болады?
### Response:
let value = 947293; |
79,791,475 | kk | JavaScript | logic_ops | advanced | JavaScript тилінде 2055 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | function isLeap() {
let y = 2055;
return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0);
} | ### Instruction:
JavaScript тилінде 2055 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
function isLeap() {
let y = 2055;
return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0);
} |
40,114,713 | en | C++ | logic_ops | advanced | Write logic to check if the year 1947 is a leap year in C++. | public bool IsLeap() {
int y = 1947;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Write logic to check if the year 1947 is a leap year in C++.
### Response:
public bool IsLeap() {
int y = 1947;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
725,030 | kk | Java | var_decl | beginner | Java тілінде 1635 мәнімен score айнымалысын қалай жариялауға болады? | int score = 1635; | ### Instruction:
Java тілінде 1635 мәнімен score айнымалысын қалай жариялауға болады?
### Response:
int score = 1635; |
136,877 | kk | Unity | sum_n | intermediate | Unity тілінде 1-ден 9004-ге дейінгі сандардың қосындысын есептейтін функция жаз. | int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
void Start() {
Debug.Log(SumToN(9004));
} | ### Instruction:
Unity тілінде 1-ден 9004-ге дейінгі сандардың қосындысын есептейтін функция жаз.
### Response:
int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
void Start() {
Debug.Log(SumToN(9004));
} |
64,725,753 | kk | Java | string_ops | intermediate | Java тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз. | public string ToUpper(string s) {
return s.ToUpper();
} | ### Instruction:
Java тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз.
### Response:
public string ToUpper(string s) {
return s.ToUpper();
} |
66,344,426 | kk | C# | string_ops | intermediate | C# тилінде жолдың палиндром екенін тексеретін функцияны жазыңыз. | public bool IsPalindrome(string s) {
int min = 0, max = s.Length - 1;
while (min < max) {
if (s[min] != s[max]) return false;
min++; max--;
}
return true;
} | ### Instruction:
C# тилінде жолдың палиндром екенін тексеретін функцияны жазыңыз.
### Response:
public bool IsPalindrome(string s) {
int min = 0, max = s.Length - 1;
while (min < max) {
if (s[min] != s[max]) return false;
min++; max--;
}
return true;
} |
365,376 | en | C# | var_decl | beginner | How to declare a variable value with value 744638 in C#? | int value = 744638; | ### Instruction:
How to declare a variable value with value 744638 in C#?
### Response:
int value = 744638; |
55,872,566 | ru | JavaScript | logic_ops | intermediate | Напишите на JavaScript логику проверки, является ли год 1964 високосным. | function isLeap() {
let y = 1964;
return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0);
} | ### Instruction:
Напишите на JavaScript логику проверки, является ли год 1964 високосным.
### Response:
function isLeap() {
let y = 1964;
return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0);
} |
3,491,334 | kk | Python | var_decl | beginner | Python тілінде 426954 мәнімен y айнымалысын қалай жариялауға болады? | y = 426954 | ### Instruction:
Python тілінде 426954 мәнімен y айнымалысын қалай жариялауға болады?
### Response:
y = 426954 |
19,840,882 | en | Java | array_ops | advanced | 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;
} |
2,794,236 | kk | Unity | var_decl | beginner | Unity тілінде 425935 мәнімен size айнымалысын қалай жариялауға болады? | int size = 425935; | ### Instruction:
Unity тілінде 425935 мәнімен size айнымалысын қалай жариялауға болады?
### Response:
int size = 425935; |
1,401,881 | ru | JavaScript | var_decl | beginner | Как объявить переменную rate со значением 49780 в JavaScript? | let rate = 49780; | ### Instruction:
Как объявить переменную rate со значением 49780 в JavaScript?
### Response:
let rate = 49780; |
1,066,909 | en | Unity | var_decl | beginner | How to declare a variable offset with value 712941 in Unity? | int offset = 712941; | ### Instruction:
How to declare a variable offset with value 712941 in Unity?
### Response:
int offset = 712941; |
498,886 | ru | Java | var_decl | beginner | Как объявить переменную timer со значением 875812 в Java? | int timer = 875812; | ### Instruction:
Как объявить переменную timer со значением 875812 в Java?
### Response:
int timer = 875812; |
48,533,344 | 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;
} |
4,081,943 | en | JavaScript | var_decl | beginner | How to declare a variable value with value 560735 in JavaScript? | let value = 560735; | ### Instruction:
How to declare a variable value with value 560735 in JavaScript?
### Response:
let value = 560735; |
12,707,903 | 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;
} |
81,345,679 | ru | C++ | array_ops | advanced | Напишите на C++ функцию, которая находит максимальное число в массиве. | public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} | ### Instruction:
Напишите на C++ функцию, которая находит максимальное число в массиве.
### Response:
public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} |
3,684,599 | ru | Python | var_decl | beginner | Как объявить переменную x со значением 501999 в Python? | x = 501999 | ### Instruction:
Как объявить переменную x со значением 501999 в Python?
### Response:
x = 501999 |
13,976,939 | ru | 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;
} |
75,568,562 | kk | Unity | logic_ops | intermediate | Unity тилінде 1973 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | public bool IsLeap() {
int y = 1973;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Unity тилінде 1973 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
public bool IsLeap() {
int y = 1973;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
4,782,018 | kk | Java | var_decl | beginner | Java тілінде 905976 мәнімен count айнымалысын қалай жариялауға болады? | int count = 905976; | ### Instruction:
Java тілінде 905976 мәнімен count айнымалысын қалай жариялауға болады?
### Response:
int count = 905976; |
81,588,943 | kk | Python | array_ops | advanced | Python тилінде тізімді керісінше айналдыратын функцияны жазыңыз. | def reverse_list(arr):
return arr[::-1] | ### Instruction:
Python тилінде тізімді керісінше айналдыратын функцияны жазыңыз.
### Response:
def reverse_list(arr):
return arr[::-1] |
460,823 | ru | JavaScript | var_decl | beginner | Как объявить переменную offset со значением 874579 в JavaScript? | let offset = 874579; | ### Instruction:
Как объявить переменную offset со значением 874579 в JavaScript?
### Response:
let offset = 874579; |
4,860,738 | kk | JavaScript | var_decl | beginner | JavaScript тілінде 942472 мәнімен value айнымалысын қалай жариялауға болады? | let value = 942472; | ### Instruction:
JavaScript тілінде 942472 мәнімен value айнымалысын қалай жариялауға болады?
### Response:
let value = 942472; |
74,595,766 | ru | Unity | logic_ops | advanced | Напишите на Unity функцию, определяющую, является ли число 276 простым. | 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:
Напишите на Unity функцию, определяющую, является ли число 276 простым.
### 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;
} |
4,486,523 | ru | Python | var_decl | beginner | Как объявить переменную speed со значением 39681 в Python? | speed = 39681 | ### Instruction:
Как объявить переменную speed со значением 39681 в Python?
### Response:
speed = 39681 |
701,682 | ru | Python | var_decl | beginner | Как объявить переменную size со значением 69376 в Python? | size = 69376 | ### Instruction:
Как объявить переменную size со значением 69376 в Python?
### Response:
size = 69376 |
17,409,077 | en | Unity | array_ops | advanced | Write a function that finds the maximum number in an array in Unity. | public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} | ### Instruction:
Write a function that finds the maximum number in an array in Unity.
### Response:
public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} |
72,656,318 | kk | JavaScript | logic_ops | intermediate | JavaScript тилінде 201 санының жай сан екенін анықтайтын функцияны жазыңыз. | function isPrime() {
let n = 201;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} | ### Instruction:
JavaScript тилінде 201 санының жай сан екенін анықтайтын функцияны жазыңыз.
### Response:
function isPrime() {
let n = 201;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} |
402,651 | kk | Python | factorial | advanced | Python тілінде 2419 санының факториалын есептейтін функция жаз. | def factorial(n):
return 1 if n <= 1 else n * factorial(n - 1)
print(factorial(2419)) | ### Instruction:
Python тілінде 2419 санының факториалын есептейтін функция жаз.
### Response:
def factorial(n):
return 1 if n <= 1 else n * factorial(n - 1)
print(factorial(2419)) |
57,012,225 | 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;
} |
47,747,886 | en | Java | logic_ops | intermediate | Write logic to check if the year 2037 is a leap year in Java. | public bool IsLeap() {
int y = 2037;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Write logic to check if the year 2037 is a leap year in Java.
### Response:
public bool IsLeap() {
int y = 2037;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
42,947,165 | en | Unity | array_ops | intermediate | Write a function that finds the maximum number in an array in Unity. | public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} | ### Instruction:
Write a function that finds the maximum number in an array in Unity.
### Response:
public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} |
3,008,774 | ru | Java | var_decl | beginner | Как объявить переменную data со значением 381200 в Java? | int data = 381200; | ### Instruction:
Как объявить переменную data со значением 381200 в Java?
### Response:
int data = 381200; |
356,695 | en | Java | sum_n | intermediate | Write a function in Java that sums numbers from 1 to 2950. | static int sumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
System.out.println(sumToN(2950)); | ### Instruction:
Write a function in Java that sums numbers from 1 to 2950.
### Response:
static int sumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
System.out.println(sumToN(2950)); |
48,940,789 | en | Unity | string_ops | advanced | 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;
} |
77,504,863 | 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(); |
28,295,813 | ru | C++ | array_ops | advanced | Напишите на C++ функцию, которая находит максимальное число в массиве. | public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} | ### Instruction:
Напишите на C++ функцию, которая находит максимальное число в массиве.
### Response:
public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} |
21,564,072 | en | Python | array_ops | intermediate | Write a function that finds the maximum number in an array in Python. | def get_max(arr):
return max(arr) | ### Instruction:
Write a function that finds the maximum number in an array in Python.
### Response:
def get_max(arr):
return max(arr) |
29,014,371 | kk | C# | string_ops | advanced | C# тилінде жолдың палиндром екенін тексеретін функцияны жазыңыз. | public bool IsPalindrome(string s) {
int min = 0, max = s.Length - 1;
while (min < max) {
if (s[min] != s[max]) return false;
min++; max--;
}
return true;
} | ### Instruction:
C# тилінде жолдың палиндром екенін тексеретін функцияны жазыңыз.
### Response:
public bool IsPalindrome(string s) {
int min = 0, max = s.Length - 1;
while (min < max) {
if (s[min] != s[max]) return false;
min++; max--;
}
return true;
} |
262,588 | kk | JavaScript | var_decl | beginner | JavaScript тілінде 864149 мәнімен count айнымалысын қалай жариялауға болады? | let count = 864149; | ### Instruction:
JavaScript тілінде 864149 мәнімен count айнымалысын қалай жариялауға болады?
### Response:
let count = 864149; |
45,304 | kk | Python | factorial | advanced | Python тілінде 1363 санының факториалын есептейтін функция жаз. | def factorial(n):
return 1 if n <= 1 else n * factorial(n - 1)
print(factorial(1363)) | ### Instruction:
Python тілінде 1363 санының факториалын есептейтін функция жаз.
### Response:
def factorial(n):
return 1 if n <= 1 else n * factorial(n - 1)
print(factorial(1363)) |
35,258,813 | kk | Unity | logic_ops | advanced | Unity тилінде 1916 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | public bool IsLeap() {
int y = 1916;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Unity тилінде 1916 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
public bool IsLeap() {
int y = 1916;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
30,923 | kk | JavaScript | func_def | intermediate | JavaScript тілінде count қабылдап, оны екі еселейтін handle функциясын жаз. | function handle(count) {
return count * 2;
} | ### Instruction:
JavaScript тілінде count қабылдап, оны екі еселейтін handle функциясын жаз.
### Response:
function handle(count) {
return count * 2;
} |
61,387,608 | 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;
} |
22,508,904 | 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аеёиоуыэюя') |
56,407,736 | kk | 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;
} |
238,077 | ru | Python | var_decl | beginner | Как объявить переменную amount со значением 528480 в Python? | amount = 528480 | ### Instruction:
Как объявить переменную amount со значением 528480 в Python?
### Response:
amount = 528480 |
323,524 | ru | C# | factorial | advanced | Напиши функцию на C#, которая вычисляет факториал числа 5295. | static long Factorial(int n) {
return n <= 1 ? 1 : n * Factorial(n - 1);
}
Console.WriteLine(Factorial(5295)); | ### Instruction:
Напиши функцию на C#, которая вычисляет факториал числа 5295.
### Response:
static long Factorial(int n) {
return n <= 1 ? 1 : n * Factorial(n - 1);
}
Console.WriteLine(Factorial(5295)); |
4,102,424 | kk | Python | var_decl | beginner | Python тілінде 735184 мәнімен health айнымалысын қалай жариялауға болады? | health = 735184 | ### Instruction:
Python тілінде 735184 мәнімен health айнымалысын қалай жариялауға болады?
### Response:
health = 735184 |
30,693,436 | kk | Java | string_ops | intermediate | Java тилінде жолдың палиндром екенін тексеретін функцияны жазыңыз. | public bool IsPalindrome(string s) {
int min = 0, max = s.Length - 1;
while (min < max) {
if (s[min] != s[max]) return false;
min++; max--;
}
return true;
} | ### Instruction:
Java тилінде жолдың палиндром екенін тексеретін функцияны жазыңыз.
### Response:
public bool IsPalindrome(string s) {
int min = 0, max = s.Length - 1;
while (min < max) {
if (s[min] != s[max]) return false;
min++; max--;
}
return true;
} |
1,628,843 | en | JavaScript | var_decl | beginner | How to declare a variable value with value 656299 in JavaScript? | let value = 656299; | ### Instruction:
How to declare a variable value with value 656299 in JavaScript?
### Response:
let value = 656299; |
3,490,073 | kk | JavaScript | var_decl | beginner | JavaScript тілінде 983685 мәнімен y айнымалысын қалай жариялауға болады? | let y = 983685; | ### Instruction:
JavaScript тілінде 983685 мәнімен y айнымалысын қалай жариялауға болады?
### Response:
let y = 983685; |
2,700,238 | en | JavaScript | var_decl | beginner | How to declare a variable amount with value 925358 in JavaScript? | let amount = 925358; | ### Instruction:
How to declare a variable amount with value 925358 in JavaScript?
### Response:
let amount = 925358; |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.