-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.cpp
More file actions
31 lines (26 loc) · 713 Bytes
/
Copy pathmain.cpp
File metadata and controls
31 lines (26 loc) · 713 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#include <iostream>
#include "stock.h"
using namespace std;
int main()
{
stock s;
int choix;
do
{
cout << "\n1.Ajouter\n2.Modifier\n3.Supprimer\n4.Rechercher\n5.Afficher\n6.Save\n7.Load\n0.Quitter\nChoix: ";
cin >> choix;
switch(choix)
{
case 1: s.ajouter(); break;
case 2: s.modifier(); break;
case 3: s.supprime(); break;
case 4: s.rechercher(); break;
case 5: s.afficher(); break;
case 6: s.save(); break;
case 7: s.charge(); break;
case 0: cout << "Bye\n"; break;
default: cout << "Choix invalide\n";
}
} while (choix != 0);
return 0;
}