Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <string>
- struct Student {
- std::string name;
- uint group;
- uint points[5];
- };
- int main()
- {
- // массив
- Student students[10];
- // ввод в массив
- for(Student &s: students) {
- std::cin >> s.name >> s.group;
- for (uint & point: s.points) std::cin >> point;
- }
- // вывод массива
- for(const Student &s: students) {
- std::cout << s.name << " " << s.group;
- for (const uint point: s.points) std::cout << point << " ";
- std::cout << '\n';
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment