Untitled
Never
#include <iostream> using namespace std; const int n = 2; struct Student { string imie; float ocena; }; void wczytaj(Student tab[n][n]) { for(int i = 0; i < n; ++i) for(int j = 0; j < n; ++j) { cout << "Podaj imie i ocene studenta: "; cin >> tab[i][j].imie >> tab[i][j].ocena; } cout << "Poprawnie wczytano tablice" << endl; } void odwroc_wiersz(Student tab[n][n], char znak, float grade) { for(int w = 0; w < n; ++w) { if(tab[w][0].imie[0] == znak && tab[w][0].ocena > grade) { // odwracanie wiersza for(int k = 0; k < n/2; ++k) swap(tab[w][k], tab[w][n-k-1]); } } } void drukuj_tab(Student tab[n][n]) { for(int i = 0; i < n; ++i) { for(int j = 0; j < n; ++j) cout << tab[i][j].imie << ' ' << tab[i][j].ocena << '\t'; cout << endl; } cout << endl; } int main() { Student A[n][n], B[n][n]; wczytaj(A); wczytaj(B); odwroc_wiersz(A, 'Z', 4); odwroc_wiersz(B, 'W', 3.5); drukuj_tab(A); drukuj_tab(B); return 0; }
Raw Text
-
https://www.macombdaily.com/2024/03/27/the-growth-matrix-reviews-2024-legit-growth-matrix-or-hidden-
39 sec ago
-
Gorgeous babe loves taking his big hard cock
19 min ago
-
shizolv
23 min ago
-
Untitled
25 min ago
-
NAKED SEXY GIRL IS GETTING FUCKED DICK INSIDE HER TIGHT PUSSY...ON MASSAGE TABLE
47 min ago
-
Vitality Mastery: Proven Practices for Peak Performance
1 hour ago
-
FAMILY SINNERS - Naughty Babe Demi Hawks Finally Gets In Her Hot Step Uncle Derrick Pierce's Pa
1 hour ago
-
Untitled
1 hour ago
-
A redhead schoolgirl came to the guy's house
1 hour ago
-
Untitled
2 hours ago