Files
ed/Practica1/main.cpp

42 lines
924 B
C++
Raw Normal View History

2026-03-14 15:11:19 +01:00
#include <iostream>
#include <fstream>
2026-03-14 17:25:51 +01:00
using namespace std;
2026-03-14 17:25:51 +01:00
void clear(){
ifstream archivo("/etc/os-release");
2026-03-14 17:25:51 +01:00
if (archivo.good()) {
system("clear");
} else {
system("cls");
2026-03-18 12:56:46 +01:00
};
};
2026-03-14 17:25:51 +01:00
2026-03-18 12:56:46 +01:00
int main(){
2026-03-14 17:25:51 +01:00
char opcion=0;
while (opcion!='8')
{
2026-03-14 15:11:19 +01:00
cout<<"SANCIONES APP. MENU PRINCIPAL"<<endl;
cout<<"===================================="<<endl;
2026-03-18 12:56:46 +01:00
cout<<"Indroduce un numero entre 1 y 8"<<endl;
2026-03-14 15:11:19 +01:00
cout<<" 1. Consultar cehiculo."<<endl;
cout<<" 2. Añadir vehiculo."<<endl;
cout<<" 3. Mostrar radares."<<endl;
cout<<" 4. Mostrar radar."<<endl;
cout<<" 5. Procsar radar."<<endl;
cout<<" 6. Mostrar fichero de sanciones."<<endl;
cout<<" 7. Mostrar cuantia de sancion."<<endl;
cout<<" 8. Salir."<<endl;
2026-03-14 17:25:51 +01:00
cout<<"Introduce un opcion";
2026-03-14 15:11:19 +01:00
opcion=getch();
2026-03-14 17:25:51 +01:00
cout<<opcion;
clear();
};
clear();
2026-03-14 15:11:19 +01:00
return 0;
};