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 |
|---|---|---|---|---|---|---|---|
67,118,203 | 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;
} |
4,829,696 | en | C++ | var_decl | beginner | How to declare a variable total with value 229127 in C++? | int total = 229127; | ### Instruction:
How to declare a variable total with value 229127 in C++?
### Response:
int total = 229127; |
32,757,256 | 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);
} |
23,251,257 | kk | C++ | array_ops | intermediate | C++ тилінде тізімнен тек жұп сандарды сүзетін функцияны жазыңыз. | public System.Collections.Generic.List<int> Filter(int[] arr) {
var res = new System.Collections.Generic.List<int>();
foreach(int x in arr) if(x % 2 == 0) res.Add(x);
return res;
} | ### Instruction:
C++ тилінде тізімнен тек жұп сандарды сүзетін функцияны жазыңыз.
### Response:
public System.Collections.Generic.List<int> Filter(int[] arr) {
var res = new System.Collections.Generic.List<int>();
foreach(int x in arr) if(x % 2 == 0) res.Add(x);
return res;
} |
2,275,373 | kk | Unity | var_decl | beginner | Unity тілінде 297290 мәнімен value айнымалысын қалай жариялауға болады? | int value = 297290; | ### Instruction:
Unity тілінде 297290 мәнімен value айнымалысын қалай жариялауға болады?
### Response:
int value = 297290; |
3,003,204 | ru | C++ | var_decl | beginner | Как объявить переменную score со значением 673110 в C++? | int score = 673110; | ### Instruction:
Как объявить переменную score со значением 673110 в C++?
### Response:
int score = 673110; |
17,124,338 | kk | C# | logic_ops | intermediate | C# тилінде 1948 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | public bool IsLeap() {
int y = 1948;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
C# тилінде 1948 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
public bool IsLeap() {
int y = 1948;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
47,622,777 | 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); |
2,377,666 | ru | C# | var_decl | beginner | Как объявить переменную limit со значением 859557 в C#? | int limit = 859557; | ### Instruction:
Как объявить переменную limit со значением 859557 в C#?
### Response:
int limit = 859557; |
79,901,067 | kk | Python | logic_ops | intermediate | Python тилінде 1973 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | def is_leap():
year = 1973
return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0) | ### Instruction:
Python тилінде 1973 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
def is_leap():
year = 1973
return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0) |
27,597,176 | ru | Python | string_ops | advanced | Напишите на Python функцию, которая переводит строку в верхний регистр. | def to_upper(s):
return s.upper() | ### Instruction:
Напишите на Python функцию, которая переводит строку в верхний регистр.
### Response:
def to_upper(s):
return s.upper() |
4,094,302 | ru | JavaScript | var_decl | beginner | Как объявить переменную health со значением 928693 в JavaScript? | let health = 928693; | ### Instruction:
Как объявить переменную health со значением 928693 в JavaScript?
### Response:
let health = 928693; |
61,088,068 | en | Python | string_ops | intermediate | Write a function that converts a string to uppercase in Python. | def to_upper(s):
return s.upper() | ### Instruction:
Write a function that converts a string to uppercase in Python.
### Response:
def to_upper(s):
return s.upper() |
41,586,841 | en | Python | logic_ops | intermediate | Write a function that determines if the number 452 is prime in Python. | def is_prime():
n = 452
return n > 1 and all(n % i != 0 for i in range(2, int(n**0.5) + 1)) | ### Instruction:
Write a function that determines if the number 452 is prime in Python.
### Response:
def is_prime():
n = 452
return n > 1 and all(n % i != 0 for i in range(2, int(n**0.5) + 1)) |
59,455,961 | 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;
} |
48,067,796 | en | Python | string_ops | advanced | Write a function that checks if a string is a palindrome in Python. | def is_palindrome(s):
return s == s[::-1] | ### Instruction:
Write a function that checks if a string is a palindrome in Python.
### Response:
def is_palindrome(s):
return s == s[::-1] |
4,791,351 | ru | C++ | var_decl | beginner | Как объявить переменную score со значением 648166 в C++? | int score = 648166; | ### Instruction:
Как объявить переменную score со значением 648166 в C++?
### Response:
int score = 648166; |
71,362,200 | kk | C# | logic_ops | intermediate | C# тилінде 196 санының жай сан екенін анықтайтын функцияны жазыңыз. | public bool IsPrime() {
int n = 196;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
C# тилінде 196 санының жай сан екенін анықтайтын функцияны жазыңыз.
### Response:
public bool IsPrime() {
int n = 196;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
3,481,018 | kk | C# | var_decl | beginner | C# тілінде 141363 мәнімен score айнымалысын қалай жариялауға болады? | int score = 141363; | ### Instruction:
C# тілінде 141363 мәнімен score айнымалысын қалай жариялауға болады?
### Response:
int score = 141363; |
37,770,275 | en | C++ | logic_ops | advanced | Write a function that determines if the number 208 is prime in C++. | public bool IsPrime() {
int n = 208;
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 208 is prime in C++.
### Response:
public bool IsPrime() {
int n = 208;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
79,019,596 | kk | Python | string_ops | intermediate | Python тилінде жолдың палиндром екенін тексеретін функцияны жазыңыз. | def is_palindrome(s):
return s == s[::-1] | ### Instruction:
Python тилінде жолдың палиндром екенін тексеретін функцияны жазыңыз.
### Response:
def is_palindrome(s):
return s == s[::-1] |
535,926 | en | C# | sum_n | intermediate | Write a function in C# that sums numbers from 1 to 7005. | static int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
Console.WriteLine(SumToN(7005)); | ### Instruction:
Write a function in C# that sums numbers from 1 to 7005.
### Response:
static int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
Console.WriteLine(SumToN(7005)); |
4,806,505 | ru | C# | var_decl | beginner | Как объявить переменную count со значением 77556 в C#? | int count = 77556; | ### Instruction:
Как объявить переменную count со значением 77556 в C#?
### Response:
int count = 77556; |
4,502,143 | kk | C# | var_decl | beginner | C# тілінде 960864 мәнімен limit айнымалысын қалай жариялауға болады? | int limit = 960864; | ### Instruction:
C# тілінде 960864 мәнімен limit айнымалысын қалай жариялауға болады?
### Response:
int limit = 960864; |
43,583,644 | 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;
} |
2,236,815 | kk | JavaScript | var_decl | beginner | JavaScript тілінде 992031 мәнімен size айнымалысын қалай жариялауға болады? | let size = 992031; | ### Instruction:
JavaScript тілінде 992031 мәнімен size айнымалысын қалай жариялауға болады?
### Response:
let size = 992031; |
53,209,126 | 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); |
82,110,695 | ru | Java | string_ops | intermediate | Напишите на 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;
} |
67,801,692 | 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;
} |
90,796,137 | kk | C# | logic_ops | intermediate | C# тилінде 1955 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | public bool IsLeap() {
int y = 1955;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
C# тилінде 1955 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
public bool IsLeap() {
int y = 1955;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
55,205,559 | en | Python | logic_ops | intermediate | Write logic to check if the year 2026 is a leap year in Python. | def is_leap():
year = 2026
return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0) | ### Instruction:
Write logic to check if the year 2026 is a leap year in Python.
### Response:
def is_leap():
year = 2026
return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0) |
78,237,456 | kk | Unity | string_ops | advanced | 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;
} |
2,740,313 | ru | Unity | var_decl | beginner | Как объявить переменную size со значением 740267 в Unity? | int size = 740267; | ### Instruction:
Как объявить переменную size со значением 740267 в Unity?
### Response:
int size = 740267; |
65,435,831 | 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;
} |
40,014,262 | ru | C# | logic_ops | intermediate | Напишите на C# функцию, определяющую, является ли число 108 простым. | public bool IsPrime() {
int n = 108;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
Напишите на C# функцию, определяющую, является ли число 108 простым.
### Response:
public bool IsPrime() {
int n = 108;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
416,179 | ru | Unity | factorial | advanced | Напиши функцию на Unity, которая вычисляет факториал числа 9865. | long Factorial(int n) {
return n <= 1 ? 1 : n * Factorial(n - 1);
}
void Start() {
Debug.Log(Factorial(9865));
} | ### Instruction:
Напиши функцию на Unity, которая вычисляет факториал числа 9865.
### Response:
long Factorial(int n) {
return n <= 1 ? 1 : n * Factorial(n - 1);
}
void Start() {
Debug.Log(Factorial(9865));
} |
23,335,174 | kk | C++ | array_ops | intermediate | C++ тилінде тізімді керісінше айналдыратын функцияны жазыңыз. | public void Reverse(int[] arr) {
System.Array.Reverse(arr);
} | ### Instruction:
C++ тилінде тізімді керісінше айналдыратын функцияны жазыңыз.
### Response:
public void Reverse(int[] arr) {
System.Array.Reverse(arr);
} |
11,347,822 | 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;
} |
20,400,932 | kk | Java | logic_ops | intermediate | Java тилінде 1923 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | public bool IsLeap() {
int y = 1923;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Java тилінде 1923 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
public bool IsLeap() {
int y = 1923;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
392,071 | en | C# | factorial | advanced | Write a function in C# that calculates the factorial of 1136. | static long Factorial(int n) {
return n <= 1 ? 1 : n * Factorial(n - 1);
}
Console.WriteLine(Factorial(1136)); | ### Instruction:
Write a function in C# that calculates the factorial of 1136.
### Response:
static long Factorial(int n) {
return n <= 1 ? 1 : n * Factorial(n - 1);
}
Console.WriteLine(Factorial(1136)); |
96,570,442 | ru | Unity | logic_ops | intermediate | Напишите на Unity логику проверки, является ли год 2080 високосным. | public bool IsLeap() {
int y = 2080;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Напишите на Unity логику проверки, является ли год 2080 високосным.
### Response:
public bool IsLeap() {
int y = 2080;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
614,877 | ru | JavaScript | factorial | advanced | Напиши функцию на JavaScript, которая вычисляет факториал числа 1734. | function factorial(n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
console.log(factorial(1734)); | ### Instruction:
Напиши функцию на JavaScript, которая вычисляет факториал числа 1734.
### Response:
function factorial(n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
console.log(factorial(1734)); |
6,278 | en | JavaScript | factorial | advanced | Write a function in JavaScript that calculates the factorial of 9824. | function factorial(n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
console.log(factorial(9824)); | ### Instruction:
Write a function in JavaScript that calculates the factorial of 9824.
### Response:
function factorial(n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
console.log(factorial(9824)); |
20,724,059 | 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,425,352 | ru | C# | var_decl | beginner | Как объявить переменную buffer со значением 915010 в C#? | int buffer = 915010; | ### Instruction:
Как объявить переменную buffer со значением 915010 в C#?
### Response:
int buffer = 915010; |
38,273,636 | 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;
} |
71,968,300 | 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) |
66,082,469 | ru | JavaScript | string_ops | advanced | Напишите на JavaScript функцию, которая переводит строку в верхний регистр. | const toUpper = s => s.toUpperCase(); | ### Instruction:
Напишите на JavaScript функцию, которая переводит строку в верхний регистр.
### Response:
const toUpper = s => s.toUpperCase(); |
261,761 | ru | Unity | var_decl | beginner | Как объявить переменную buffer со значением 324442 в Unity? | int buffer = 324442; | ### Instruction:
Как объявить переменную buffer со значением 324442 в Unity?
### Response:
int buffer = 324442; |
314,520 | ru | Java | sum_n | intermediate | Напиши функцию на Java, которая считает сумму чисел от 1 до 3119. | static int sumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
System.out.println(sumToN(3119)); | ### Instruction:
Напиши функцию на Java, которая считает сумму чисел от 1 до 3119.
### Response:
static int sumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
System.out.println(sumToN(3119)); |
3,507,055 | en | Python | var_decl | beginner | How to declare a variable speed with value 776632 in Python? | speed = 776632 | ### Instruction:
How to declare a variable speed with value 776632 in Python?
### Response:
speed = 776632 |
33,261,893 | 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();
} |
24,045,925 | kk | JavaScript | string_ops | intermediate | JavaScript тилінде мәтіндегі дауысты әріптердің санын есептейтін функцияны жазыңыз. | const countVowels = s => (s.match(/[aeiou]/gi) || []).length; | ### Instruction:
JavaScript тилінде мәтіндегі дауысты әріптердің санын есептейтін функцияны жазыңыз.
### Response:
const countVowels = s => (s.match(/[aeiou]/gi) || []).length; |
4,036,469 | kk | Unity | var_decl | beginner | Unity тілінде 617356 мәнімен speed айнымалысын қалай жариялауға болады? | int speed = 617356; | ### Instruction:
Unity тілінде 617356 мәнімен speed айнымалысын қалай жариялауға болады?
### Response:
int speed = 617356; |
25,430,485 | 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;
} |
2,615,731 | ru | C# | var_decl | beginner | Как объявить переменную y со значением 784754 в C#? | int y = 784754; | ### Instruction:
Как объявить переменную y со значением 784754 в C#?
### Response:
int y = 784754; |
93,798,928 | ru | C# | logic_ops | intermediate | Напишите на C# логику проверки, является ли год 2002 високосным. | public bool IsLeap() {
int y = 2002;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Напишите на C# логику проверки, является ли год 2002 високосным.
### Response:
public bool IsLeap() {
int y = 2002;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
1,886,501 | en | C# | var_decl | beginner | How to declare a variable buffer with value 947600 in C#? | int buffer = 947600; | ### Instruction:
How to declare a variable buffer with value 947600 in C#?
### Response:
int buffer = 947600; |
88,361,124 | kk | Java | array_ops | advanced | Java тилінде жиымдағы ең үлкен санды табатын функцияны жазыңыз. | public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} | ### Instruction:
Java тилінде жиымдағы ең үлкен санды табатын функцияны жазыңыз.
### Response:
public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} |
88,746,937 | 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();
} |
599,492 | en | Unity | sum_n | intermediate | Write a function in Unity that sums numbers from 1 to 3618. | int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
void Start() {
Debug.Log(SumToN(3618));
} | ### Instruction:
Write a function in Unity that sums numbers from 1 to 3618.
### Response:
int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
void Start() {
Debug.Log(SumToN(3618));
} |
32,857,356 | ru | Java | string_ops | intermediate | Напишите на Java функцию, которая переводит строку в верхний регистр. | public string ToUpper(string s) {
return s.ToUpper();
} | ### Instruction:
Напишите на Java функцию, которая переводит строку в верхний регистр.
### Response:
public string ToUpper(string s) {
return s.ToUpper();
} |
99,330,682 | ru | Unity | array_ops | advanced | Напишите на 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;
} |
685,506 | kk | C# | factorial | advanced | C# тілінде 9536 санының факториалын есептейтін функция жаз. | static long Factorial(int n) {
return n <= 1 ? 1 : n * Factorial(n - 1);
}
Console.WriteLine(Factorial(9536)); | ### Instruction:
C# тілінде 9536 санының факториалын есептейтін функция жаз.
### Response:
static long Factorial(int n) {
return n <= 1 ? 1 : n * Factorial(n - 1);
}
Console.WriteLine(Factorial(9536)); |
14,841,201 | en | C++ | array_ops | advanced | 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;
} |
4,332,491 | en | C++ | var_decl | beginner | How to declare a variable data with value 596563 in C++? | int data = 596563; | ### Instruction:
How to declare a variable data with value 596563 in C++?
### Response:
int data = 596563; |
24,529,348 | 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;
} |
4,730,599 | kk | C++ | var_decl | beginner | C++ тілінде 211674 мәнімен total айнымалысын қалай жариялауға болады? | int total = 211674; | ### Instruction:
C++ тілінде 211674 мәнімен total айнымалысын қалай жариялауға болады?
### Response:
int total = 211674; |
89,775,601 | 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(''); |
343,368 | en | Unity | sum_n | intermediate | Write a function in Unity that sums numbers from 1 to 7363. | int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
void Start() {
Debug.Log(SumToN(7363));
} | ### Instruction:
Write a function in Unity that sums numbers from 1 to 7363.
### Response:
int SumToN(int n) {
int s = 0;
for (int i = 1; i <= n; i++) s += i;
return s;
}
void Start() {
Debug.Log(SumToN(7363));
} |
830,929 | kk | Unity | var_decl | beginner | Unity тілінде 781870 мәнімен rate айнымалысын қалай жариялауға болады? | int rate = 781870; | ### Instruction:
Unity тілінде 781870 мәнімен rate айнымалысын қалай жариялауға болады?
### Response:
int rate = 781870; |
135,640 | ru | C++ | factorial | advanced | Напиши функцию на C++, которая вычисляет факториал числа 1386. | long long factorial(int n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
std::cout << factorial(1386) << std::endl; | ### Instruction:
Напиши функцию на C++, которая вычисляет факториал числа 1386.
### Response:
long long factorial(int n) {
return n <= 1 ? 1 : n * factorial(n - 1);
}
std::cout << factorial(1386) << std::endl; |
81,917,873 | kk | JavaScript | string_ops | intermediate | JavaScript тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз. | const toUpper = s => s.toUpperCase(); | ### Instruction:
JavaScript тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз.
### Response:
const toUpper = s => s.toUpperCase(); |
91,253,329 | 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;
} |
82,799,933 | 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;
} |
42,010,229 | kk | C# | logic_ops | advanced | C# тилінде 1900 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. | public bool IsLeap() {
int y = 1900;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
C# тилінде 1900 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
### Response:
public bool IsLeap() {
int y = 1900;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
10,536,870 | kk | C# | logic_ops | intermediate | C# тилінде 38 санының жай сан екенін анықтайтын функцияны жазыңыз. | public bool IsPrime() {
int n = 38;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} | ### Instruction:
C# тилінде 38 санының жай сан екенін анықтайтын функцияны жазыңыз.
### Response:
public bool IsPrime() {
int n = 38;
if (n <= 1) return false;
for (int i = 2; i * i <= n; i++) if (n % i == 0) return false;
return true;
} |
20,769,663 | kk | Unity | string_ops | intermediate | Unity тилінде жолдың палиндром екенін тексеретін функцияны жазыңыз. | public bool IsPalindrome(string s) {
int min = 0, max = s.Length - 1;
while (min < max) {
if (s[min] != s[max]) return false;
min++; max--;
}
return true;
} | ### Instruction:
Unity тилінде жолдың палиндром екенін тексеретін функцияны жазыңыз.
### Response:
public bool IsPalindrome(string s) {
int min = 0, max = s.Length - 1;
while (min < max) {
if (s[min] != s[max]) return false;
min++; max--;
}
return true;
} |
1,751,087 | ru | JavaScript | var_decl | beginner | Как объявить переменную buffer со значением 84255 в JavaScript? | let buffer = 84255; | ### Instruction:
Как объявить переменную buffer со значением 84255 в JavaScript?
### Response:
let buffer = 84255; |
78,307,939 | 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;
} |
83,539,101 | ru | Python | logic_ops | advanced | Напишите на Python функцию, определяющую, является ли число 58 простым. | def is_prime():
n = 58
return n > 1 and all(n % i != 0 for i in range(2, int(n**0.5) + 1)) | ### Instruction:
Напишите на Python функцию, определяющую, является ли число 58 простым.
### Response:
def is_prime():
n = 58
return n > 1 and all(n % i != 0 for i in range(2, int(n**0.5) + 1)) |
1,745,676 | ru | Unity | var_decl | beginner | Как объявить переменную size со значением 107929 в Unity? | int size = 107929; | ### Instruction:
Как объявить переменную size со значением 107929 в Unity?
### Response:
int size = 107929; |
734,332 | en | Java | var_decl | beginner | How to declare a variable health with value 425413 in Java? | int health = 425413; | ### Instruction:
How to declare a variable health with value 425413 in Java?
### Response:
int health = 425413; |
570,334 | kk | Unity | var_decl | beginner | Unity тілінде 394070 мәнімен y айнымалысын қалай жариялауға болады? | int y = 394070; | ### Instruction:
Unity тілінде 394070 мәнімен y айнымалысын қалай жариялауға болады?
### Response:
int y = 394070; |
13,731,710 | en | C++ | array_ops | intermediate | Write a function that finds the maximum number in an array in C++. | public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} | ### Instruction:
Write a function that finds the maximum number in an array in C++.
### Response:
public int GetMax(int[] arr) {
int max = arr[0];
foreach(int x in arr) if(x > max) max = x;
return max;
} |
80,596,002 | ru | Unity | string_ops | advanced | Напишите на 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;
} |
18,134,011 | en | Unity | logic_ops | advanced | Write logic to check if the year 2061 is a leap year in Unity. | public bool IsLeap() {
int y = 2061;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} | ### Instruction:
Write logic to check if the year 2061 is a leap year in Unity.
### Response:
public bool IsLeap() {
int y = 2061;
return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0);
} |
1,338,252 | kk | Unity | var_decl | beginner | Unity тілінде 859825 мәнімен score айнымалысын қалай жариялауға болады? | int score = 859825; | ### Instruction:
Unity тілінде 859825 мәнімен score айнымалысын қалай жариялауға болады?
### Response:
int score = 859825; |
4,560,693 | kk | C# | var_decl | beginner | C# тілінде 580246 мәнімен result айнымалысын қалай жариялауға болады? | int result = 580246; | ### Instruction:
C# тілінде 580246 мәнімен result айнымалысын қалай жариялауға болады?
### Response:
int result = 580246; |
4,981,615 | ru | C# | var_decl | beginner | Как объявить переменную data со значением 141336 в C#? | int data = 141336; | ### Instruction:
Как объявить переменную data со значением 141336 в C#?
### Response:
int data = 141336; |
73,071,771 | en | Java | array_ops | advanced | Write a function that reverses a list in Java. | public void Reverse(int[] arr) {
System.Array.Reverse(arr);
} | ### Instruction:
Write a function that reverses a list in Java.
### Response:
public void Reverse(int[] arr) {
System.Array.Reverse(arr);
} |
19,157,016 | 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;
} |
2,877,661 | ru | Python | var_decl | beginner | Как объявить переменную offset со значением 884076 в Python? | offset = 884076 | ### Instruction:
Как объявить переменную offset со значением 884076 в Python?
### Response:
offset = 884076 |
4,206,549 | kk | Java | var_decl | beginner | Java тілінде 575258 мәнімен buffer айнымалысын қалай жариялауға болады? | int buffer = 575258; | ### Instruction:
Java тілінде 575258 мәнімен buffer айнымалысын қалай жариялауға болады?
### Response:
int buffer = 575258; |
17,047,989 | ru | JavaScript | string_ops | intermediate | Напишите на JavaScript функцию, которая считает количество гласных букв в тексте. | const countVowels = s => (s.match(/[aeiou]/gi) || []).length; | ### Instruction:
Напишите на JavaScript функцию, которая считает количество гласных букв в тексте.
### Response:
const countVowels = s => (s.match(/[aeiou]/gi) || []).length; |
98,874,434 | en | JavaScript | logic_ops | intermediate | Write logic to check if the year 1994 is a leap year in JavaScript. | function isLeap() {
let y = 1994;
return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0);
} | ### Instruction:
Write logic to check if the year 1994 is a leap year in JavaScript.
### Response:
function isLeap() {
let y = 1994;
return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0);
} |
4,517,832 | en | Python | var_decl | beginner | How to declare a variable speed with value 513481 in Python? | speed = 513481 | ### Instruction:
How to declare a variable speed with value 513481 in Python?
### Response:
speed = 513481 |
424,269 | en | Unity | var_decl | beginner | How to declare a variable buffer with value 666782 in Unity? | int buffer = 666782; | ### Instruction:
How to declare a variable buffer with value 666782 in Unity?
### Response:
int buffer = 666782; |
17,782,789 | 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;
} |
18,754,663 | 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] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.