josiftepe

Untitled

Nov 28th, 2020
45
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.70 KB | None | 0 0
  1. #include <iostream>
  2. #include <cmath>
  3. #include <vector>
  4. #include <queue>
  5. using namespace std;
  6. typedef long long ll;
  7. struct student{
  8.     string ime, prezime;
  9.     int broj_na_indeks, godini;
  10.     student(){}
  11.     student(string _ime, string _prezime, int _broj_na_indeks, int _godini) {
  12.         ime = _ime;
  13.         prezime = _prezime;
  14.         broj_na_indeks = _broj_na_indeks;
  15.         godini = _godini;
  16.     }
  17. };
  18. int main()
  19. {
  20.     ios_base::sync_with_stdio(false);
  21.     // vnesi ime na student, prezime na student, broj na indeks i godini i ispecati gi
  22.     int n(10); // isto so n = 10
  23.     cout << n << endl;
  24.     student s = student("j", "t", 12, 12);
  25.     cout << s.ime << endl;
  26.     return 0;
  27. }
  28.  
Advertisement
Add Comment
Please, Sign In to add comment