consolidate all repos to one for archive
This commit is contained in:
27
semester_2/programiranje_2/naloga0602/main.cpp
Normal file
27
semester_2/programiranje_2/naloga0602/main.cpp
Normal file
@@ -0,0 +1,27 @@
|
||||
#include <iostream>
|
||||
#include "Vlak.h"
|
||||
|
||||
int main() {
|
||||
Vlak nik;
|
||||
Vagon pot(34,56,TipVag::Potniski);
|
||||
Vagon tov(23,67,TipVag::Tovorni);
|
||||
Lokomotiva lok(56,78,1000);
|
||||
nik.addPriklucek(&pot);
|
||||
nik.addPriklucek(&tov);
|
||||
nik.addPriklucek(&lok);
|
||||
|
||||
std::cout << nik.toString();
|
||||
std::cout << nik.lenghtOfTranin();
|
||||
std::cout << "\n\n\n";
|
||||
|
||||
|
||||
|
||||
std::vector<Prikljucek*> gen = Vlak::generate(6);
|
||||
|
||||
for(auto t: gen){
|
||||
std::cout << t->toString();
|
||||
}
|
||||
|
||||
|
||||
return 0;
|
||||
}
|
||||
Reference in New Issue
Block a user