| 1 Неизвестный, 17 ноября 2025 г. 9:44:39 |
| как?
|
|
|
| 2 КТЛ-чел Билял, 28 октября 2025 г. 19:06:35 |
| #include <bits/stdc++.h> using namespace std; int main() { int N; cin >> N; int days[100]; int odd[100], even[100]; int oddCount = 0, evenCount = 0; for (int i = 0; i < N; i++) { cin >> days[i]; if (days[i] % 2 == 0) { even[evenCount++] = days[i]; } else { odd[oddCount++] = days[i]; } } for (int i = 0; i < oddCount; i++) { cout << odd[i]; if (i < oddCount - 1) cout << " "; } cout << "\n"; for (int i = 0; i < evenCount; i++) { cout << even[i]; if (i < evenCount - 1) cout << " "; } cout << "\n"; if (evenCount >= oddCount) cout << "YES"; else cout << "NO"; cout << "\n"; return 0; }
|
|
|
| 3 Моисеев Кирилл Дмитревич, 06 августа 2025 г. 21:57:54 |
| <script>alert(123)</script>
|
|
|
| 4 Моисеев Кирилл Дмитревич, 06 августа 2025 г. 21:57:02 |
| kl;
|
|
|
| 5 Яковлев Антон Евгеньевич, 27 июля 2025 г. 20:50:37 |
| казалось бы, задание что было ранее намного сложнее, но теперь задача на уровне подсчеты четных нечетных цифр,капец
|
|
|
| 6 Казаков Алексей Александрович, 17 июля 2025 г. 17:04:23 |
| Оказывается моя ошибка была в том, что я выводил значения элементов массива с [].
|
|
|
| 7 Айтуган, 22 апреля 2025 г. 18:57:47 |
| Кайырбай Акансери thanks;
|
|
|
| 8 К И А, 30 марта 2025 г. 16:19:49 |
| Кайырбай Акансери, 26 декабря 2021 г. 15:01:05 Если кол-во троек и четверок равны то нужно вывести YES Спасибо тебе, добрый программист
|
|
|
| 9 Кузиев, 17 марта 2025 г. 10:18:50 |
| #include <iostream> using namespace std; int main() { int N; cin >> N; int days[100]; int odd[100], even[100]; int oddCount = 0, evenCount = 0; for (int i = 0; i < N; i++) { cin >> days[i]; if (days[i] % 2 == 0) { even[evenCount++] = days[i]; } else { odd[oddCount++] = days[i]; } } for (int i = 0; i < oddCount; i++) { cout << odd[i]; if (i < oddCount - 1) cout << " "; } cout << "\n"; for (int i = 0; i < evenCount; i++) { cout << even[i]; if (i < evenCount - 1) cout << " "; } cout << "\n"; if (evenCount >= oddCount) cout << "YES"; else cout << "NO"; cout << "\n"; return 0; }
|
|
|
| 10 Рословцев Матвей Олегович, 24 февраля 2025 г. 14:39:13 |
| #include<iostream> #include<string> using namespace std; int main(){ int a; cin>>a; int arr[a]; if(a%2==0){ cout<<-1; }else{ for(int i=1;i<=a;i++){ for(int j=1;j<=a;j++){ if(j==a/2+1)cout<<1<<" "; else if(i==a/2+1)cout<<1<<" "; else cout<<0<<" "; } cout<<endl; } } return 0; }
|
|
|
| 11 Рословцев Матвей Олегович, 24 февраля 2025 г. 14:38:17 |
| #include <bits/stdc++.h> using namespace std; int main() { int a[4]={0},i,n,k; cin>>n; a[0]=n-8; a[1]=n+8; a[2]=n-1; a[3]=n+1; if(n%8==0) a[3]=-1; if(n%8==1) a[2]=-1; sort(a,a+4); for(i=0; i<4; i++) if(a[i]>0 && a[i]<65) cout<<a[i]<<" "; return 0; }#include <bits/stdc++.h> using namespace std; int main() { int a[4]={0},i,n,k; cin>>n; a[0]=n-8; a[1]=n+8; a[2]=n-1; a[3]=n+1; if(n%8==0) a[3]=-1; if(n%8==1) a[2]=-1; sort(a,a+4); for(i=0; i<4; i++) if(a[i]>0 && a[i]<65) cout<<a[i]<<" "; return 0; }#include <bits/stdc++.h> using namespace std; int main() { int a[4]={0},i,n,k; cin>>n; a[0]=n-8; a[1]=n+8; a[2]=n-1; a[3]=n+1; if(n%8==0) a[3]=-1; if(n%8==1) a[2]=-1; sort(a,a+4); for(i=0; i<4; i++) if(a[i]>0 && a[i]<65) cout<<a[i]<<" "; return 0; }#
|
|
|
| 12 Расул, 01 февраля 2025 г. 8:29:59 |
| n = int(input()) arr = list(map(int, input().split())) arr.sort() arr = arr[::-1] c = True for i in range(n-2): if(arr[i]+arr[i+1]>arr[i+2] and arr[i]+arr[i+2]>arr[i+1] and arr[i+2]+arr[i+1]>arr[i]): print(arr[i+2], arr[i+1], arr[i]) c = False break if (c): print(-1)
|
|
|
| 13 Руслан Истамкулов, 13 января 2025 г. 13:29:06 |
| n = int(input()) for _ in range(n): m = list(map(int, input().split())) h = [x for x in m if x % 2 == 0] p = [x for x in m if x % 2 != 0] print(*p) print(*h) print("YES" if len(p) < len(h) else "NO") где ошибка
|
|
|
| 14 Чаросхон, 13 января 2025 г. 9:41:13 |
| n=int(input()) cnt=0 c=True k=1 while(c): b=bin(k) if(int(b[2:])<=n): cnt+=1 k+=1 else: break print(cnt)
|
|
|
| 15 Расул, 13 января 2025 г. 8:49:27 |
| #include<iostream> #include<string> using namespace std; int main(){ int a; cin>>a; int arr[a]; if(a%2==0){ cout<<-1; }else{ for(int i=1;i<=a;i++){ for(int j=1;j<=a;j++){ if(j==a/2+1)cout<<1<<" "; else if(i==a/2+1)cout<<1<<" "; else cout<<0<<" "; } cout<<endl; } } return 0; }
|
|
|
| 16 Расул, 13 января 2025 г. 8:48:56 |
| a = int(input()) if a % 2 == 0: print(-1) else: for i in range(a): for j in range(a): if j == a // 2 or i == a // 2: print(1, end=" ") else: print(0, end=" ") print()
|
|
|
| 17 Давлатбек, 03 декабря 2024 г. 13:33:49 |
| #include <iostream> #include <vector> using namespace std; int main() { int n,sum=0; cin >> n; vector<int> arr(n); for (int i = 0; i < n; i++) { cin >> arr[i]; sum += arr[i]; } cout << sum - n + 1; }
|
|
|
| 18 Расул, 03 декабря 2024 г. 13:23:05 |
| #include <iostream> using namespace std; int main() { int n,k,s; cin>>n>>k>>s; if(n==1) { cout<<1; } else if(n>(k+s)) { cout<<(k+s)*2+1; } else cout<<2*n-1; return 0; }
|
|
|
| 19 Расул, 03 декабря 2024 г. 13:12:27 |
| #include <iostream> using namespace std; int main() { int n,k,s; cin>>n>>k>>s; if(n+k+s==3) { cout<<1; } else if(n>(k+s)) { cout<<n+k+s; } else cout<<2*n-1; return 0; }
|
|
|
| 20 Шайназаров Эрбол Медербекович, 03 декабря 2024 г. 9:28:55 |
| @Кайырбай Акансери Спасибо, твой совет помог
|
|
|