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
812,455
kk
Java
var_decl
beginner
Java тілінде 765325 мәнімен limit айнымалысын қалай жариялауға болады?
int limit = 765325;
### Instruction: Java тілінде 765325 мәнімен limit айнымалысын қалай жариялауға болады? ### Response: int limit = 765325;
68,376,386
ru
C#
logic_ops
advanced
Напишите на C# функцию, определяющую, является ли число 227 простым.
public bool IsPrime() { int n = 227; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
### Instruction: Напишите на C# функцию, определяющую, является ли число 227 простым. ### Response: public bool IsPrime() { int n = 227; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
662,067
ru
Java
factorial
advanced
Напиши функцию на Java, которая вычисляет факториал числа 553.
static long factorial(int n) { return n <= 1 ? 1 : n * factorial(n - 1); } System.out.println(factorial(553));
### Instruction: Напиши функцию на Java, которая вычисляет факториал числа 553. ### Response: static long factorial(int n) { return n <= 1 ? 1 : n * factorial(n - 1); } System.out.println(factorial(553));
3,539,876
kk
Python
var_decl
beginner
Python тілінде 173447 мәнімен data айнымалысын қалай жариялауға болады?
data = 173447
### Instruction: Python тілінде 173447 мәнімен data айнымалысын қалай жариялауға болады? ### Response: data = 173447
352,920
ru
Java
factorial
advanced
Напиши функцию на Java, которая вычисляет факториал числа 9816.
static long factorial(int n) { return n <= 1 ? 1 : n * factorial(n - 1); } System.out.println(factorial(9816));
### Instruction: Напиши функцию на Java, которая вычисляет факториал числа 9816. ### Response: static long factorial(int n) { return n <= 1 ? 1 : n * factorial(n - 1); } System.out.println(factorial(9816));
47,209,119
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(); }
1,965,229
kk
Unity
var_decl
beginner
Unity тілінде 80544 мәнімен limit айнымалысын қалай жариялауға болады?
int limit = 80544;
### Instruction: Unity тілінде 80544 мәнімен limit айнымалысын қалай жариялауға болады? ### Response: int limit = 80544;
398,336
kk
C++
sum_n
intermediate
C++ тілінде 1-ден 5707-ге дейінгі сандардың қосындысын есептейтін функция жаз.
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(5707) << std::endl;
### Instruction: C++ тілінде 1-ден 5707-ге дейінгі сандардың қосындысын есептейтін функция жаз. ### 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(5707) << std::endl;
49,176,394
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; }
34,540,824
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); }
26,746,621
kk
C++
logic_ops
intermediate
C++ тилінде 134 санының жай сан екенін анықтайтын функцияны жазыңыз.
public bool IsPrime() { int n = 134; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
### Instruction: C++ тилінде 134 санының жай сан екенін анықтайтын функцияны жазыңыз. ### Response: public bool IsPrime() { int n = 134; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
3,068,221
en
Python
var_decl
beginner
How to declare a variable weight with value 410728 in Python?
weight = 410728
### Instruction: How to declare a variable weight with value 410728 in Python? ### Response: weight = 410728
23,846
en
JavaScript
sum_n
intermediate
Write a function in JavaScript that sums numbers from 1 to 8280.
function sumToN(n) { let s = 0; for (let i = 1; i <= n; i++) s += i; return s; } console.log(sumToN(8280));
### Instruction: Write a function in JavaScript that sums numbers from 1 to 8280. ### Response: function sumToN(n) { let s = 0; for (let i = 1; i <= n; i++) s += i; return s; } console.log(sumToN(8280));
60,956,700
kk
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; }
3,946,991
en
JavaScript
var_decl
beginner
How to declare a variable offset with value 189699 in JavaScript?
let offset = 189699;
### Instruction: How to declare a variable offset with value 189699 in JavaScript? ### Response: let offset = 189699;
530,445
en
C++
var_decl
beginner
How to declare a variable offset with value 86178 in C++?
int offset = 86178;
### Instruction: How to declare a variable offset with value 86178 in C++? ### Response: int offset = 86178;
23,011,551
en
JavaScript
logic_ops
advanced
Write logic to check if the year 2080 is a leap year in JavaScript.
function isLeap() { let y = 2080; return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0); }
### Instruction: Write logic to check if the year 2080 is a leap year in JavaScript. ### Response: function isLeap() { let y = 2080; return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0); }
3,170,299
kk
C#
var_decl
beginner
C# тілінде 127841 мәнімен timer айнымалысын қалай жариялауға болады?
int timer = 127841;
### Instruction: C# тілінде 127841 мәнімен timer айнымалысын қалай жариялауға болады? ### Response: int timer = 127841;
59,787,451
ru
Unity
array_ops
intermediate
Напишите на Unity функцию, которая разворачивает список задом наперед.
public void Reverse(int[] arr) { System.Array.Reverse(arr); }
### Instruction: Напишите на Unity функцию, которая разворачивает список задом наперед. ### Response: public void Reverse(int[] arr) { System.Array.Reverse(arr); }
470,999
en
Python
sum_n
intermediate
Write a function in Python that sums numbers from 1 to 6785.
def sum_to_n(n): return sum(range(1, n + 1)) print(sum_to_n(6785))
### Instruction: Write a function in Python that sums numbers from 1 to 6785. ### Response: def sum_to_n(n): return sum(range(1, n + 1)) print(sum_to_n(6785))
27,548,495
en
Unity
logic_ops
advanced
Write a function that determines if the number 71 is prime in Unity.
public bool IsPrime() { int n = 71; 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 71 is prime in Unity. ### Response: public bool IsPrime() { int n = 71; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
65,667,706
en
C#
logic_ops
intermediate
Write logic to check if the year 2034 is a leap year in C#.
public bool IsLeap() { int y = 2034; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
### Instruction: Write logic to check if the year 2034 is a leap year in C#. ### Response: public bool IsLeap() { int y = 2034; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
30,150,771
en
JavaScript
string_ops
intermediate
Write a function that counts vowels in a text in JavaScript.
const countVowels = s => (s.match(/[aeiou]/gi) || []).length;
### Instruction: Write a function that counts vowels in a text in JavaScript. ### Response: const countVowels = s => (s.match(/[aeiou]/gi) || []).length;
20,848,915
kk
Python
logic_ops
intermediate
Python тилінде 1976 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
def is_leap(): year = 1976 return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0)
### Instruction: Python тилінде 1976 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. ### Response: def is_leap(): year = 1976 return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0)
82,761,642
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; }
4,730,132
en
Unity
var_decl
beginner
How to declare a variable score with value 753451 in Unity?
int score = 753451;
### Instruction: How to declare a variable score with value 753451 in Unity? ### Response: int score = 753451;
159,572
ru
C++
factorial
advanced
Напиши функцию на C++, которая вычисляет факториал числа 2458.
long long factorial(int n) { return n <= 1 ? 1 : n * factorial(n - 1); } std::cout << factorial(2458) << std::endl;
### Instruction: Напиши функцию на C++, которая вычисляет факториал числа 2458. ### Response: long long factorial(int n) { return n <= 1 ? 1 : n * factorial(n - 1); } std::cout << factorial(2458) << std::endl;
12,255,973
en
Unity
array_ops
advanced
Write a function that filters only even numbers from a list in Unity.
public System.Collections.Generic.List<int> Filter(int[] arr) { var res = new System.Collections.Generic.List<int>(); foreach(int x in arr) if(x % 2 == 0) res.Add(x); return res; }
### Instruction: Write a function that filters only even numbers from a list in Unity. ### Response: public System.Collections.Generic.List<int> Filter(int[] arr) { var res = new System.Collections.Generic.List<int>(); foreach(int x in arr) if(x % 2 == 0) res.Add(x); return res; }
75,059,145
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(); }
21,008,925
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); }
2,409,992
kk
C#
var_decl
beginner
C# тілінде 583663 мәнімен data айнымалысын қалай жариялауға болады?
int data = 583663;
### Instruction: C# тілінде 583663 мәнімен data айнымалысын қалай жариялауға болады? ### Response: int data = 583663;
4,387,611
kk
Python
var_decl
beginner
Python тілінде 560776 мәнімен score айнымалысын қалай жариялауға болады?
score = 560776
### Instruction: Python тілінде 560776 мәнімен score айнымалысын қалай жариялауға болады? ### Response: score = 560776
4,700,576
en
JavaScript
var_decl
beginner
How to declare a variable amount with value 806090 in JavaScript?
let amount = 806090;
### Instruction: How to declare a variable amount with value 806090 in JavaScript? ### Response: let amount = 806090;
553,375
en
C#
factorial
advanced
Write a function in C# that calculates the factorial of 8279.
static long Factorial(int n) { return n <= 1 ? 1 : n * Factorial(n - 1); } Console.WriteLine(Factorial(8279));
### Instruction: Write a function in C# that calculates the factorial of 8279. ### Response: static long Factorial(int n) { return n <= 1 ? 1 : n * Factorial(n - 1); } Console.WriteLine(Factorial(8279));
13,797,819
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аеёиоуыэюя')
217,757
ru
Java
sum_n
intermediate
Напиши функцию на Java, которая считает сумму чисел от 1 до 124.
static int sumToN(int n) { int s = 0; for (int i = 1; i <= n; i++) s += i; return s; } System.out.println(sumToN(124));
### Instruction: Напиши функцию на Java, которая считает сумму чисел от 1 до 124. ### Response: static int sumToN(int n) { int s = 0; for (int i = 1; i <= n; i++) s += i; return s; } System.out.println(sumToN(124));
76,998,937
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; }
1,678,343
en
JavaScript
var_decl
beginner
How to declare a variable x with value 279202 in JavaScript?
let x = 279202;
### Instruction: How to declare a variable x with value 279202 in JavaScript? ### Response: let x = 279202;
23,435,876
en
C#
logic_ops
advanced
Write a function that determines if the number 277 is prime in C#.
public bool IsPrime() { int n = 277; 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 277 is prime in C#. ### Response: public bool IsPrime() { int n = 277; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
81,511,595
kk
Python
string_ops
advanced
Python тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз.
def to_upper(s): return s.upper()
### Instruction: Python тилінде жолды жоғарғы регистрге ауыстыратын функцияны жазыңыз. ### Response: def to_upper(s): return s.upper()
764,010
en
Java
var_decl
beginner
How to declare a variable limit with value 206334 in Java?
int limit = 206334;
### Instruction: How to declare a variable limit with value 206334 in Java? ### Response: int limit = 206334;
49,556,762
kk
JavaScript
string_ops
advanced
JavaScript тилінде жолдың палиндром екенін тексеретін функцияны жазыңыз.
const isPalindrome = s => s === s.split('').reverse().join('');
### Instruction: JavaScript тилінде жолдың палиндром екенін тексеретін функцияны жазыңыз. ### Response: const isPalindrome = s => s === s.split('').reverse().join('');
13,342,147
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,842,507
ru
Unity
var_decl
beginner
Как объявить переменную size со значением 793899 в Unity?
int size = 793899;
### Instruction: Как объявить переменную size со значением 793899 в Unity? ### Response: int size = 793899;
21,480,474
en
JavaScript
string_ops
advanced
Write a function that checks if a string is a palindrome in JavaScript.
const isPalindrome = s => s === s.split('').reverse().join('');
### Instruction: Write a function that checks if a string is a palindrome in JavaScript. ### Response: const isPalindrome = s => s === s.split('').reverse().join('');
65,146,045
kk
JavaScript
logic_ops
advanced
JavaScript тилінде 2085 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
function isLeap() { let y = 2085; return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0); }
### Instruction: JavaScript тилінде 2085 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. ### Response: function isLeap() { let y = 2085; return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0); }
32,869
en
C#
sum_n
intermediate
Write a function in C# that sums numbers from 1 to 7536.
static int SumToN(int n) { int s = 0; for (int i = 1; i <= n; i++) s += i; return s; } Console.WriteLine(SumToN(7536));
### Instruction: Write a function in C# that sums numbers from 1 to 7536. ### Response: static int SumToN(int n) { int s = 0; for (int i = 1; i <= n; i++) s += i; return s; } Console.WriteLine(SumToN(7536));
1,003,266
ru
C++
var_decl
beginner
Как объявить переменную count со значением 593378 в C++?
int count = 593378;
### Instruction: Как объявить переменную count со значением 593378 в C++? ### Response: int count = 593378;
11,728,937
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; }
70,582,082
en
JavaScript
logic_ops
intermediate
Write a function that determines if the number 421 is prime in JavaScript.
function isPrime() { let n = 421; 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 421 is prime in JavaScript. ### Response: function isPrime() { let n = 421; if (n <= 1) return false; for (let i = 2; i * i <= n; i++) if (n % i === 0) return false; return true; }
1,118,469
ru
JavaScript
var_decl
beginner
Как объявить переменную level со значением 652061 в JavaScript?
let level = 652061;
### Instruction: Как объявить переменную level со значением 652061 в JavaScript? ### Response: let level = 652061;
2,028,421
ru
C#
var_decl
beginner
Как объявить переменную weight со значением 752040 в C#?
int weight = 752040;
### Instruction: Как объявить переменную weight со значением 752040 в C#? ### Response: int weight = 752040;
24,549,934
en
JavaScript
array_ops
intermediate
Write a function that filters only even numbers from a list in JavaScript.
const filterEven = arr => arr.filter(x => x % 2 === 0);
### Instruction: Write a function that filters only even numbers from a list in JavaScript. ### Response: const filterEven = arr => arr.filter(x => x % 2 === 0);
76,229,252
ru
C++
logic_ops
intermediate
Напишите на C++ логику проверки, является ли год 2094 високосным.
public bool IsLeap() { int y = 2094; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
### Instruction: Напишите на C++ логику проверки, является ли год 2094 високосным. ### Response: public bool IsLeap() { int y = 2094; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
18,668,905
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; }
87,998,877
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);
58,614,954
en
Java
array_ops
intermediate
Write a function that filters only even numbers from a list in Java.
public System.Collections.Generic.List<int> Filter(int[] arr) { var res = new System.Collections.Generic.List<int>(); foreach(int x in arr) if(x % 2 == 0) res.Add(x); return res; }
### Instruction: Write a function that filters only even numbers from a list in Java. ### Response: public System.Collections.Generic.List<int> Filter(int[] arr) { var res = new System.Collections.Generic.List<int>(); foreach(int x in arr) if(x % 2 == 0) res.Add(x); return res; }
86,070,361
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аеёиоуыэюя')
86,292,734
kk
JavaScript
string_ops
advanced
JavaScript тилінде мәтіндегі дауысты әріптердің санын есептейтін функцияны жазыңыз.
const countVowels = s => (s.match(/[aeiou]/gi) || []).length;
### Instruction: JavaScript тилінде мәтіндегі дауысты әріптердің санын есептейтін функцияны жазыңыз. ### Response: const countVowels = s => (s.match(/[aeiou]/gi) || []).length;
404,782
ru
C++
var_decl
beginner
Как объявить переменную level со значением 505898 в C++?
int level = 505898;
### Instruction: Как объявить переменную level со значением 505898 в C++? ### Response: int level = 505898;
17,323,445
kk
C++
logic_ops
advanced
C++ тилінде 2078 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
public bool IsLeap() { int y = 2078; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
### Instruction: C++ тилінде 2078 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. ### Response: public bool IsLeap() { int y = 2078; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
48,265,028
kk
JavaScript
array_ops
advanced
JavaScript тилінде жиымдағы ең үлкен санды табатын функцияны жазыңыз.
const getMax = arr => Math.max(...arr);
### Instruction: JavaScript тилінде жиымдағы ең үлкен санды табатын функцияны жазыңыз. ### Response: const getMax = arr => Math.max(...arr);
3,439,518
ru
JavaScript
var_decl
beginner
Как объявить переменную total со значением 77054 в JavaScript?
let total = 77054;
### Instruction: Как объявить переменную total со значением 77054 в JavaScript? ### Response: let total = 77054;
2,511,183
en
JavaScript
var_decl
beginner
How to declare a variable speed with value 533534 in JavaScript?
let speed = 533534;
### Instruction: How to declare a variable speed with value 533534 in JavaScript? ### Response: let speed = 533534;
92,481,310
kk
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; }
91,832,590
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); }
90,121,513
en
C#
array_ops
intermediate
Write a function that reverses a list in C#.
public void Reverse(int[] arr) { System.Array.Reverse(arr); }
### Instruction: Write a function that reverses a list in C#. ### Response: public void Reverse(int[] arr) { System.Array.Reverse(arr); }
38,655,153
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; }
55,587,658
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); }
91,687,920
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]
2,730,395
kk
JavaScript
var_decl
beginner
JavaScript тілінде 40109 мәнімен rate айнымалысын қалай жариялауға болады?
let rate = 40109;
### Instruction: JavaScript тілінде 40109 мәнімен rate айнымалысын қалай жариялауға болады? ### Response: let rate = 40109;
947,794
ru
C++
var_decl
beginner
Как объявить переменную health со значением 2326 в C++?
int health = 2326;
### Instruction: Как объявить переменную health со значением 2326 в C++? ### Response: int health = 2326;
83,373,271
kk
C#
logic_ops
advanced
C# тилінде 2071 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
public bool IsLeap() { int y = 2071; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
### Instruction: C# тилінде 2071 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. ### Response: public bool IsLeap() { int y = 2071; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
76,944,085
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; }
4,344,270
ru
C++
var_decl
beginner
Как объявить переменную buffer со значением 452972 в C++?
int buffer = 452972;
### Instruction: Как объявить переменную buffer со значением 452972 в C++? ### Response: int buffer = 452972;
69,502,814
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; }
442,721
en
C++
factorial
advanced
Write a function in C++ that calculates the factorial of 8678.
long long factorial(int n) { return n <= 1 ? 1 : n * factorial(n - 1); } std::cout << factorial(8678) << std::endl;
### Instruction: Write a function in C++ that calculates the factorial of 8678. ### Response: long long factorial(int n) { return n <= 1 ? 1 : n * factorial(n - 1); } std::cout << factorial(8678) << std::endl;
26,058,198
ru
Java
string_ops
advanced
Напишите на Java функцию, которая проверяет, является ли строка палиндромом.
public bool IsPalindrome(string s) { int min = 0, max = s.Length - 1; while (min < max) { if (s[min] != s[max]) return false; min++; max--; } return true; }
### Instruction: Напишите на Java функцию, которая проверяет, является ли строка палиндромом. ### Response: public bool IsPalindrome(string s) { int min = 0, max = s.Length - 1; while (min < max) { if (s[min] != s[max]) return false; min++; max--; } return true; }
98,439,842
kk
JavaScript
logic_ops
advanced
JavaScript тилінде 2097 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
function isLeap() { let y = 2097; return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0); }
### Instruction: JavaScript тилінде 2097 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. ### Response: function isLeap() { let y = 2097; return y % 4 === 0 && (y % 100 !== 0 || y % 400 === 0); }
402,698
en
JavaScript
var_decl
beginner
How to declare a variable amount with value 429767 in JavaScript?
let amount = 429767;
### Instruction: How to declare a variable amount with value 429767 in JavaScript? ### Response: let amount = 429767;
4,964
ru
JavaScript
sum_n
intermediate
Напиши функцию на JavaScript, которая считает сумму чисел от 1 до 1638.
function sumToN(n) { let s = 0; for (let i = 1; i <= n; i++) s += i; return s; } console.log(sumToN(1638));
### Instruction: Напиши функцию на JavaScript, которая считает сумму чисел от 1 до 1638. ### Response: function sumToN(n) { let s = 0; for (let i = 1; i <= n; i++) s += i; return s; } console.log(sumToN(1638));
4,358,664
kk
JavaScript
var_decl
beginner
JavaScript тілінде 787491 мәнімен limit айнымалысын қалай жариялауға болады?
let limit = 787491;
### Instruction: JavaScript тілінде 787491 мәнімен limit айнымалысын қалай жариялауға болады? ### Response: let limit = 787491;
1,974,636
kk
Java
var_decl
beginner
Java тілінде 630861 мәнімен buffer айнымалысын қалай жариялауға болады?
int buffer = 630861;
### Instruction: Java тілінде 630861 мәнімен buffer айнымалысын қалай жариялауға болады? ### Response: int buffer = 630861;
1,768,768
ru
JavaScript
var_decl
beginner
Как объявить переменную health со значением 945222 в JavaScript?
let health = 945222;
### Instruction: Как объявить переменную health со значением 945222 в JavaScript? ### Response: let health = 945222;
14,173,213
kk
JavaScript
array_ops
advanced
JavaScript тилінде тізімді керісінше айналдыратын функцияны жазыңыз.
const reverseArr = arr => arr.reverse();
### Instruction: JavaScript тилінде тізімді керісінше айналдыратын функцияны жазыңыз. ### Response: const reverseArr = arr => arr.reverse();
1,382,875
kk
Python
var_decl
beginner
Python тілінде 725048 мәнімен index айнымалысын қалай жариялауға болады?
index = 725048
### Instruction: Python тілінде 725048 мәнімен index айнымалысын қалай жариялауға болады? ### Response: index = 725048
17,490,541
en
C++
logic_ops
intermediate
Write logic to check if the year 1988 is a leap year in C++.
public bool IsLeap() { int y = 1988; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
### Instruction: Write logic to check if the year 1988 is a leap year in C++. ### Response: public bool IsLeap() { int y = 1988; return y % 4 == 0 && (y % 100 != 0 || y % 400 == 0); }
85,584,912
ru
Python
array_ops
advanced
Напишите на Python функцию, которая разворачивает список задом наперед.
def reverse_list(arr): return arr[::-1]
### Instruction: Напишите на Python функцию, которая разворачивает список задом наперед. ### Response: def reverse_list(arr): return arr[::-1]
85,602,972
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; }
93,407,078
en
JavaScript
array_ops
advanced
Write a function that filters only even numbers from a list in JavaScript.
const filterEven = arr => arr.filter(x => x % 2 === 0);
### Instruction: Write a function that filters only even numbers from a list in JavaScript. ### Response: const filterEven = arr => arr.filter(x => x % 2 === 0);
3,682,736
en
C#
var_decl
beginner
How to declare a variable health with value 702699 in C#?
int health = 702699;
### Instruction: How to declare a variable health with value 702699 in C#? ### Response: int health = 702699;
2,653,482
ru
Python
var_decl
beginner
Как объявить переменную result со значением 550271 в Python?
result = 550271
### Instruction: Как объявить переменную result со значением 550271 в Python? ### Response: result = 550271
152,654
ru
JavaScript
factorial
advanced
Напиши функцию на JavaScript, которая вычисляет факториал числа 5713.
function factorial(n) { return n <= 1 ? 1 : n * factorial(n - 1); } console.log(factorial(5713));
### Instruction: Напиши функцию на JavaScript, которая вычисляет факториал числа 5713. ### Response: function factorial(n) { return n <= 1 ? 1 : n * factorial(n - 1); } console.log(factorial(5713));
76,482,991
kk
Python
logic_ops
advanced
Python тилінде 1950 жылы кібісе жыл екенін тексеретін логиканы жазыңыз.
def is_leap(): year = 1950 return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0)
### Instruction: Python тилінде 1950 жылы кібісе жыл екенін тексеретін логиканы жазыңыз. ### Response: def is_leap(): year = 1950 return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0)
67,424,770
en
Unity
string_ops
advanced
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; }
2,674,247
ru
Unity
var_decl
beginner
Как объявить переменную limit со значением 93230 в Unity?
int limit = 93230;
### Instruction: Как объявить переменную limit со значением 93230 в Unity? ### Response: int limit = 93230;
82,677,517
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; }
22,281,423
ru
Unity
array_ops
advanced
Напишите на 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; }
3,429,735
ru
C#
var_decl
beginner
Как объявить переменную count со значением 212914 в C#?
int count = 212914;
### Instruction: Как объявить переменную count со значением 212914 в C#? ### Response: int count = 212914;
19,612,662
ru
Java
logic_ops
advanced
Напишите на Java функцию, определяющую, является ли число 143 простым.
public bool IsPrime() { int n = 143; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }
### Instruction: Напишите на Java функцию, определяющую, является ли число 143 простым. ### Response: public bool IsPrime() { int n = 143; if (n <= 1) return false; for (int i = 2; i * i <= n; i++) if (n % i == 0) return false; return true; }