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 |
|---|---|---|---|---|---|---|---|
60,930,199 | kk | 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;
} |
56,326,187 | ru | JavaScript | string_ops | advanced | Напишите на JavaScript функцию, которая считает количество гласных букв в тексте. | const countVowels = s => (s.match(/[aeiou]/gi) || []).length; | ### Instruction:
Напишите на JavaScript функцию, которая считает количество гласных букв в тексте.
### Response:
const countVowels = s => (s.match(/[aeiou]/gi) || []).length; |
2,950,460 | en | Unity | var_decl | beginner | How to declare a variable x with value 908515 in Unity? | int x = 908515; | ### Instruction:
How to declare a variable x with value 908515 in Unity?
### Response:
int x = 908515; |
76,616,346 | en | Python | array_ops | advanced | 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) |
4,387,708 | ru | Python | var_decl | beginner | Как объявить переменную rate со значением 811559 в Python? | rate = 811559 | ### Instruction:
Как объявить переменную rate со значением 811559 в Python?
### Response:
rate = 811559 |
457,284 | en | Java | var_decl | beginner | How to declare a variable data with value 236731 in Java? | int data = 236731; | ### Instruction:
How to declare a variable data with value 236731 in Java?
### Response:
int data = 236731; |
3,501,085 | kk | C# | var_decl | beginner | C# тілінде 244379 мәнімен index айнымалысын қалай жариялауға болады? | int index = 244379; | ### Instruction:
C# тілінде 244379 мәнімен index айнымалысын қалай жариялауға болады?
### Response:
int index = 244379; |
1,583,605 | kk | Unity | var_decl | beginner | Unity тілінде 182404 мәнімен index айнымалысын қалай жариялауға болады? | int index = 182404; | ### Instruction:
Unity тілінде 182404 мәнімен index айнымалысын қалай жариялауға болады?
### Response:
int index = 182404; |
70,049,145 | 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] |
78,361,710 | 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();
} |
75,042,136 | ru | Java | logic_ops | intermediate | Напишите на Java логику проверки, является ли год 1945 високосным. | public bool IsLeap() {
int y = 1945;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Напишите на Java логику проверки, является ли год 1945 високосным.
### Response:
public bool IsLeap() {
int y = 1945;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
72,105,255 | en | C++ | logic_ops | intermediate | Write a function that determines if the number 500 is prime in C++. | public bool IsPrime() {
int n = 500;
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 500 is prime in C++.
### Response:
public bool IsPrime() {
int n = 500;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
45,971,564 | kk | C++ | string_ops | intermediate | C++ тилінде мәтіндегі дауысты әріптердің санын есептейтін функцияны жазыңыз. | public int CountVowels(string s) {
int c = 0;
foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++;
return c;
} | ### Instruction:
C++ тилінде мәтіндегі дауысты әріптердің санын есептейтін функцияны жазыңыз.
### Response:
public int CountVowels(string s) {
int c = 0;
foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++;
return c;
} |
3,369,881 | ru | C# | var_decl | beginner | Как объявить переменную rate со значением 330881 в C#? | int rate = 330881; | ### Instruction:
Как объявить переменную rate со значением 330881 в C#?
### Response:
int rate = 330881; |
83,420,226 | 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;
} |
99,846,945 | kk | Java | string_ops | advanced | Java тилінде мәтіндегі дауысты әріптердің санын есептейтін функцияны жазыңыз. | public int CountVowels(string s) {
int c = 0;
foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++;
return c;
} | ### Instruction:
Java тилінде мәтіндегі дауысты әріптердің санын есептейтін функцияны жазыңыз.
### Response:
public int CountVowels(string s) {
int c = 0;
foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++;
return c;
} |
49,342,416 | en | Unity | logic_ops | advanced | Write logic to check if the year 1982 is a leap year in Unity. | public bool IsLeap() {
int y = 1982;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Write logic to check if the year 1982 is a leap year in Unity.
### Response:
public bool IsLeap() {
int y = 1982;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
19,386,349 | ru | Unity | logic_ops | advanced | Напишите на Unity логику проверки, является ли год 2043 високосным. | public bool IsLeap() {
int y = 2043;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Напишите на Unity логику проверки, является ли год 2043 високосным.
### Response:
public bool IsLeap() {
int y = 2043;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
39,992,795 | ru | C# | string_ops | intermediate | Напишите на C# функцию, которая проверяет, является ли строка палиндромом. | public bool IsPalindrome(string s) {
int min = 0, max = s.Length - 1;
while (min < max) {
if (s[min] != s[max]) return false;
min++; max--;
}
return true;
} | ### Instruction:
Напишите на C# функцию, которая проверяет, является ли строка палиндромом.
### Response:
public bool IsPalindrome(string s) {
int min = 0, max = s.Length - 1;
while (min < max) {
if (s[min] != s[max]) return false;
min++; max--;
}
return true;
} |
4,813,172 | kk | JavaScript | var_decl | beginner | JavaScript тілінде 300181 мәнімен score айнымалысын қалай жариялауға болады? | let score = 300181; | ### Instruction:
JavaScript тілінде 300181 мәнімен score айнымалысын қалай жариялауға болады?
### Response:
let score = 300181; |
89,446,898 | 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();
} |
4,816,994 | ru | Python | var_decl | beginner | Как объявить переменную speed со значением 937412 в Python? | speed = 937412 | ### Instruction:
Как объявить переменную speed со значением 937412 в Python?
### Response:
speed = 937412 |
1,993,718 | en | C++ | var_decl | beginner | How to declare a variable timer with value 535626 in C++? | int timer = 535626; | ### Instruction:
How to declare a variable timer with value 535626 in C++?
### Response:
int timer = 535626; |
58,128,606 | ru | Python | string_ops | advanced | Напишите на Python функцию, которая переводит строку в верхний регистр. | def to_upper(s):
return s.upper() | ### Instruction:
Напишите на Python функцию, которая переводит строку в верхний регистр.
### Response:
def to_upper(s):
return s.upper() |
3,505,212 | ru | Unity | var_decl | beginner | Как объявить переменную score со значением 914092 в Unity? | int score = 914092; | ### Instruction:
Как объявить переменную score со значением 914092 в Unity?
### Response:
int score = 914092; |
85,090,650 | ru | Unity | logic_ops | intermediate | Напишите на Unity функцию, определяющую, является ли число 496 простым. | public bool IsPrime() {
int n = 496;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
Напишите на Unity функцию, определяющую, является ли число 496 простым.
### Response:
public bool IsPrime() {
int n = 496;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
74,678,093 | ru | 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аеёиоуыэюя') |
94,245,128 | kk | JavaScript | logic_ops | advanced | JavaScript тилінде 176 санының жай сан екенін анықтайтын функцияны жазыңыз. | function isPrime() {
let n = 176;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} | ### Instruction:
JavaScript тилінде 176 санының жай сан екенін анықтайтын функцияны жазыңыз.
### Response:
function isPrime() {
let n = 176;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} |
1,459,672 | en | Java | var_decl | beginner | How to declare a variable score with value 197254 in Java? | int score = 197254; | ### Instruction:
How to declare a variable score with value 197254 in Java?
### Response:
int score = 197254; |
2,310,984 | ru | C++ | var_decl | beginner | Как объявить переменную limit со значением 115197 в C++? | int limit = 115197; | ### Instruction:
Как объявить переменную limit со значением 115197 в C++?
### Response:
int limit = 115197; |
4,639,525 | ru | C++ | var_decl | beginner | Как объявить переменную weight со значением 76563 в C++? | int weight = 76563; | ### Instruction:
Как объявить переменную weight со значением 76563 в C++?
### Response:
int weight = 76563; |
86,809,388 | ru | Java | array_ops | intermediate | Напишите на Java функцию, которая находит максимальное число в массиве. | public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} | ### Instruction:
Напишите на Java функцию, которая находит максимальное число в массиве.
### Response:
public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} |
52,937,565 | ru | Python | array_ops | advanced | Напишите на Python функцию, которая разворачивает список задом наперед. | def reverse_list(arr):
return arr[::-1] | ### Instruction:
Напишите на Python функцию, которая разворачивает список задом наперед.
### Response:
def reverse_list(arr):
return arr[::-1] |
42,157,586 | 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,039,981 | ru | C++ | var_decl | beginner | Как объявить переменную weight со значением 22351 в C++? | int weight = 22351; | ### Instruction:
Как объявить переменную weight со значением 22351 в C++?
### Response:
int weight = 22351; |
31,737,242 | ru | JavaScript | string_ops | advanced | Напишите на JavaScript функцию, которая считает количество гласных букв в тексте. | const countVowels = s => (s.match(/[aeiou]/gi) || []).length; | ### Instruction:
Напишите на JavaScript функцию, которая считает количество гласных букв в тексте.
### Response:
const countVowels = s => (s.match(/[aeiou]/gi) || []).length; |
855,054 | ru | Python | var_decl | beginner | Как объявить переменную offset со значением 996682 в Python? | offset = 996682 | ### Instruction:
Как объявить переменную offset со значением 996682 в Python?
### Response:
offset = 996682 |
2,486,716 | kk | C# | var_decl | beginner | C# тілінде 49955 мәнімен timer айнымалысын қалай жариялауға болады? | int timer = 49955; | ### Instruction:
C# тілінде 49955 мәнімен timer айнымалысын қалай жариялауға болады?
### Response:
int timer = 49955; |
284,094 | en | C++ | sum_n | intermediate | Write a function in C++ that sums numbers from 1 to 8850. | 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(8850) << std::endl; | ### Instruction:
Write a function in C++ that sums numbers from 1 to 8850.
### 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(8850) << std::endl; |
75,572,459 | en | C# | logic_ops | advanced | Write logic to check if the year 1943 is a leap year in C#. | public bool IsLeap() {
int y = 1943;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Write logic to check if the year 1943 is a leap year in C#.
### Response:
public bool IsLeap() {
int y = 1943;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
2,483,239 | en | C# | var_decl | beginner | How to declare a variable value with value 312026 in C#? | int value = 312026; | ### Instruction:
How to declare a variable value with value 312026 in C#?
### Response:
int value = 312026; |
53,235,722 | 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;
} |
2,792,869 | kk | C# | var_decl | beginner | C# тілінде 646047 мәнімен offset айнымалысын қалай жариялауға болады? | int offset = 646047; | ### Instruction:
C# тілінде 646047 мәнімен offset айнымалысын қалай жариялауға болады?
### Response:
int offset = 646047; |
14,523,408 | 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;
} |
3,181,376 | en | Python | var_decl | beginner | How to declare a variable score with value 702254 in Python? | score = 702254 | ### Instruction:
How to declare a variable score with value 702254 in Python?
### Response:
score = 702254 |
264,069 | kk | Java | sum_n | intermediate | Java тілінде 1-ден 9583-ге дейінгі сандардың қосындысын есептейтін функция жаз. | static int sumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
System.out.println(sumToN(9583)); | ### Instruction:
Java тілінде 1-ден 9583-ге дейінгі сандардың қосындысын есептейтін функция жаз.
### Response:
static int sumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
System.out.println(sumToN(9583)); |
49,958,054 | ru | JavaScript | logic_ops | advanced | Напишите на JavaScript функцию, определяющую, является ли число 271 простым. | function isPrime() {
let n = 271;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} | ### Instruction:
Напишите на JavaScript функцию, определяющую, является ли число 271 простым.
### Response:
function isPrime() {
let n = 271;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} |
4,970,102 | kk | C++ | var_decl | beginner | C++ тілінде 211190 мәнімен index айнымалысын қалай жариялауға болады? | int index = 211190; | ### Instruction:
C++ тілінде 211190 мәнімен index айнымалысын қалай жариялауға болады?
### Response:
int index = 211190; |
2,015,319 | kk | Java | var_decl | beginner | Java тілінде 987125 мәнімен amount айнымалысын қалай жариялауға болады? | int amount = 987125; | ### Instruction:
Java тілінде 987125 мәнімен amount айнымалысын қалай жариялауға болады?
### Response:
int amount = 987125; |
35,158,967 | 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();
} |
15,748,382 | kk | C++ | logic_ops | intermediate | C++ тилінде 1911 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | public bool IsLeap() {
int y = 1911;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
C++ тилінде 1911 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
public bool IsLeap() {
int y = 1911;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
96,054,246 | kk | 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); |
57,138,618 | kk | C# | logic_ops | intermediate | C# тилінде 450 санының жай сан екенін анықтайтын функцияны жазыңыз. | public bool IsPrime() {
int n = 450;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
C# тилінде 450 санының жай сан екенін анықтайтын функцияны жазыңыз.
### Response:
public bool IsPrime() {
int n = 450;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
10,075 | ru | C# | sum_n | intermediate | Напиши функцию на C#, которая считает сумму чисел от 1 до 7379. | static int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
Console.WriteLine(SumToN(7379)); | ### Instruction:
Напиши функцию на C#, которая считает сумму чисел от 1 до 7379.
### Response:
static int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
Console.WriteLine(SumToN(7379)); |
80,943,144 | ru | JavaScript | logic_ops | advanced | Напишите на JavaScript логику проверки, является ли год 2084 високосным. | function isLeap() {
let y = 2084;
return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0);
} | ### Instruction:
Напишите на JavaScript логику проверки, является ли год 2084 високосным.
### Response:
function isLeap() {
let y = 2084;
return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0);
} |
2,731,028 | ru | Java | var_decl | beginner | Как объявить переменную offset со значением 977850 в Java? | int offset = 977850; | ### Instruction:
Как объявить переменную offset со значением 977850 в Java?
### Response:
int offset = 977850; |
99,216 | ru | Java | factorial | advanced | Напиши функцию на Java, которая вычисляет факториал числа 2455. | static long factorial(int n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
System.out.println(factorial(2455)); | ### Instruction:
Напиши функцию на Java, которая вычисляет факториал числа 2455.
### Response:
static long factorial(int n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
System.out.println(factorial(2455)); |
96,724,221 | kk | JavaScript | array_ops | intermediate | JavaScript тилінде жиымдағы ең үлкен санды табатын функцияны жазыңыз. | const getMax = arr => Math.max(...arr); | ### Instruction:
JavaScript тилінде жиымдағы ең үлкен санды табатын функцияны жазыңыз.
### Response:
const getMax = arr => Math.max(...arr); |
4,276,791 | ru | Java | var_decl | beginner | Как объявить переменную y со значением 394248 в Java? | int y = 394248; | ### Instruction:
Как объявить переменную y со значением 394248 в Java?
### Response:
int y = 394248; |
50,720,209 | 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;
} |
86,200,213 | 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); |
47,539,807 | en | Python | string_ops | advanced | Write a function that converts a string to uppercase in Python. | def to_upper(s):
return s.upper() | ### Instruction:
Write a function that converts a string to uppercase in Python.
### Response:
def to_upper(s):
return s.upper() |
69,289,641 | en | Java | logic_ops | advanced | Write a function that determines if the number 387 is prime in Java. | public bool IsPrime() {
int n = 387;
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 387 is prime in Java.
### Response:
public bool IsPrime() {
int n = 387;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
3,539,168 | ru | Unity | var_decl | beginner | Как объявить переменную amount со значением 747141 в Unity? | int amount = 747141; | ### Instruction:
Как объявить переменную amount со значением 747141 в Unity?
### Response:
int amount = 747141; |
46,006,310 | kk | JavaScript | logic_ops | advanced | JavaScript тилінде 2050 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | function isLeap() {
let y = 2050;
return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0);
} | ### Instruction:
JavaScript тилінде 2050 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
function isLeap() {
let y = 2050;
return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0);
} |
3,885,636 | en | Python | var_decl | beginner | How to declare a variable value with value 856653 in Python? | value = 856653 | ### Instruction:
How to declare a variable value with value 856653 in Python?
### Response:
value = 856653 |
32,747,753 | 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;
} |
58,947,860 | 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;
} |
3,582,978 | ru | C++ | var_decl | beginner | Как объявить переменную index со значением 784878 в C++? | int index = 784878; | ### Instruction:
Как объявить переменную index со значением 784878 в C++?
### Response:
int index = 784878; |
3,106,233 | kk | Python | var_decl | beginner | Python тілінде 645131 мәнімен level айнымалысын қалай жариялауға болады? | level = 645131 | ### Instruction:
Python тілінде 645131 мәнімен level айнымалысын қалай жариялауға болады?
### Response:
level = 645131 |
27,686,819 | ru | JavaScript | logic_ops | intermediate | Напишите на JavaScript функцию, определяющую, является ли число 142 простым. | function isPrime() {
let n = 142;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} | ### Instruction:
Напишите на JavaScript функцию, определяющую, является ли число 142 простым.
### Response:
function isPrime() {
let n = 142;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} |
3,858,277 | en | Unity | var_decl | beginner | How to declare a variable index with value 136651 in Unity? | int index = 136651; | ### Instruction:
How to declare a variable index with value 136651 in Unity?
### Response:
int index = 136651; |
4,433,771 | ru | Java | var_decl | beginner | Как объявить переменную amount со значением 738308 в Java? | int amount = 738308; | ### Instruction:
Как объявить переменную amount со значением 738308 в Java?
### Response:
int amount = 738308; |
382,178 | en | JavaScript | var_decl | beginner | How to declare a variable weight with value 79467 in JavaScript? | let weight = 79467; | ### Instruction:
How to declare a variable weight with value 79467 in JavaScript?
### Response:
let weight = 79467; |
1,534,293 | en | Unity | var_decl | beginner | How to declare a variable x with value 853776 in Unity? | int x = 853776; | ### Instruction:
How to declare a variable x with value 853776 in Unity?
### Response:
int x = 853776; |
89,301,868 | en | JavaScript | logic_ops | advanced | Write a function that determines if the number 136 is prime in JavaScript. | function isPrime() {
let n = 136;
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 136 is prime in JavaScript.
### Response:
function isPrime() {
let n = 136;
if (n <= 1) return false;
for (let i = 2; i * i <= n; i++) if (n % i === 0) return false;
return true;
} |
63,239,644 | kk | Python | string_ops | advanced | Python тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз. | def to_upper(s):
return s.upper() | ### Instruction:
Python тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз.
### Response:
def to_upper(s):
return s.upper() |
3,250,889 | en | Python | var_decl | beginner | How to declare a variable amount with value 887265 in Python? | amount = 887265 | ### Instruction:
How to declare a variable amount with value 887265 in Python?
### Response:
amount = 887265 |
47,654,777 | 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;
} |
32,458,997 | 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);
} |
1,244,154 | kk | C# | var_decl | beginner | C# тілінде 354442 мәнімен timer айнымалысын қалай жариялауға болады? | int timer = 354442; | ### Instruction:
C# тілінде 354442 мәнімен timer айнымалысын қалай жариялауға болады?
### Response:
int timer = 354442; |
31,810,434 | 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);
} |
15,964,898 | 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;
} |
69,294,218 | en | Java | logic_ops | intermediate | Write a function that determines if the number 328 is prime in Java. | public bool IsPrime() {
int n = 328;
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 328 is prime in Java.
### Response:
public bool IsPrime() {
int n = 328;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
16,662,086 | kk | C# | logic_ops | advanced | C# тилінде 1980 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | public bool IsLeap() {
int y = 1980;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
C# тилінде 1980 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
public bool IsLeap() {
int y = 1980;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
442,508 | kk | C# | var_decl | beginner | C# тілінде 648312 мәнімен speed айнымалысын қалай жариялауға болады? | int speed = 648312; | ### Instruction:
C# тілінде 648312 мәнімен speed айнымалысын қалай жариялауға болады?
### Response:
int speed = 648312; |
133,722 | en | Python | factorial | advanced | Write a function in Python that calculates the factorial of 2343. | def factorial(n):
return 1 if n <= 1 else n * factorial(n - 1)
print(factorial(2343)) | ### Instruction:
Write a function in Python that calculates the factorial of 2343.
### Response:
def factorial(n):
return 1 if n <= 1 else n * factorial(n - 1)
print(factorial(2343)) |
41,813,764 | kk | C# | string_ops | intermediate | C# тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз. | public string ToUpper(string s) {
return s.ToUpper();
} | ### Instruction:
C# тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз.
### Response:
public string ToUpper(string s) {
return s.ToUpper();
} |
47,415,074 | 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;
} |
25,633,177 | kk | JavaScript | string_ops | intermediate | JavaScript тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз. | const toUpper = s => s.toUpperCase(); | ### Instruction:
JavaScript тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз.
### Response:
const toUpper = s => s.toUpperCase(); |
2,257,879 | ru | C++ | var_decl | beginner | Как объявить переменную amount со значением 893036 в C++? | int amount = 893036; | ### Instruction:
Как объявить переменную amount со значением 893036 в C++?
### Response:
int amount = 893036; |
1,526,080 | en | Java | var_decl | beginner | How to declare a variable size with value 694423 in Java? | int size = 694423; | ### Instruction:
How to declare a variable size with value 694423 in Java?
### Response:
int size = 694423; |
2,368,706 | ru | JavaScript | var_decl | beginner | Как объявить переменную result со значением 953379 в JavaScript? | let result = 953379; | ### Instruction:
Как объявить переменную result со значением 953379 в JavaScript?
### Response:
let result = 953379; |
15,641,916 | 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;
} |
3,215,216 | en | C# | var_decl | beginner | How to declare a variable y with value 73962 in C#? | int y = 73962; | ### Instruction:
How to declare a variable y with value 73962 in C#?
### Response:
int y = 73962; |
93,862,592 | ru | JavaScript | logic_ops | intermediate | Напишите на JavaScript логику проверки, является ли год 2006 високосным. | function isLeap() {
let y = 2006;
return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0);
} | ### Instruction:
Напишите на JavaScript логику проверки, является ли год 2006 високосным.
### Response:
function isLeap() {
let y = 2006;
return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0);
} |
18,801,038 | kk | C# | logic_ops | intermediate | C# тилінде 430 санының жай сан екенін анықтайтын функцияны жазыңыз. | public bool IsPrime() {
int n = 430;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
C# тилінде 430 санының жай сан екенін анықтайтын функцияны жазыңыз.
### Response:
public bool IsPrime() {
int n = 430;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
501,370 | kk | Unity | sum_n | intermediate | Unity тілінде 1-ден 9142-ге дейінгі сандардың қосындысын есептейтін функция жаз. | int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
void Start() {
Debug.Log(SumToN(9142));
} | ### Instruction:
Unity тілінде 1-ден 9142-ге дейінгі сандардың қосындысын есептейтін функция жаз.
### Response:
int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
void Start() {
Debug.Log(SumToN(9142));
} |
3,489,469 | en | Unity | var_decl | beginner | How to declare a variable rate with value 13265 in Unity? | int rate = 13265; | ### Instruction:
How to declare a variable rate with value 13265 in Unity?
### Response:
int rate = 13265; |
92,507,977 | en | Unity | string_ops | intermediate | Write a function that counts vowels in a text in Unity. | 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 Unity.
### Response:
public int CountVowels(string s) {
int c = 0;
foreach(char ch in s.ToLower()) if("aeiou".Contains(ch)) c++;
return c;
} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.