NotesWhat is notes.io?

Notes brand slogan

Notes - notes.io

//Bibliotheken einbinden
#include <iostream>
#include <Windows.h>
using namespace std;

#define NEWLINE 'n' //Definition Neue Zeile
#define TAB 't' //Definition Tabulator


int main() //Hauptteil

{

system ("color 9"); //Konsolen Schrift Farbe



//Variablendefinition

int iZeit = 0; //Parkzeit
double dBetrag = 0.0; //Zahlbetrag
char cTaste; //Taste
const int iTakt = 15; //Zeittakt
const double dEinheit = 0.50; //Betrag pro Zeittakt

//do { //Beginn erste Schleife

system ("cls"); //Bilschirminhalt löschen
cout << NEWLINE << NEWLINE;
cout << TAB << "|-|-|-|-|-|-|-|-|-|-| BEDIENUNGSANLEITUNG |-|-|-|-|";
cout << "-|-|-|-|-|-|-|-|-|-|" << NEWLINE;
cout << TAB << "|" << TAB << TAB << TAB << TAB << TAB << TAB << TAB << TAB << " |" << NEWLINE;
cout << TAB << "| Um den Parkautomaten zu aktiveren, Betaetigen Sie bitte die P-Taste" << " |";
cout << NEWLINE; //Design
cout << TAB << "| Bei jedem betaetigen der P-Taste wird die Parkdauer um 15 Minuten" << " |" << NEWLINE;
cout << TAB << "| verlängert" << TAB << TAB << TAB << TAB << TAB << TAB << TAB << " |";
cout << NEWLINE; //Design
cout << TAB << "| Pro 15 Minuten kostet Ihnen das Parken 50 Cent" << TAB << TAB << " |";
cout << NEWLINE; //Design
cout << TAB << "| Sobald Sie die gewuenschte Dater erreicht haben," << TAB << TAB << " |" << NEWLINE;
cout << TAB << "| betaetigen Sie bitte die O-Taste um die Zahlung abzuschliessen |";
cout << NEWLINE; //Design
cout << TAB << "| BITTE BEACHTEN: MAXIMALE PARKDAUER IST 1 STUNDE!" << TAB << TAB << " |" << NEWLINE;
cout << TAB << "|---------------------------------------------------------------------|" << NEWLINE;
cout << NEWLINE << NEWLINE; //Bediendungsanleitung und Design Ende


//Beginn des Programms

marke:; //Sprungstart

//Eingabe 1
cout << TAB << TAB << "Taste: " << TAB;
cin >> cTaste; //Tastenwahl

if (cTaste == 'p' || cTaste == 'P')

{
//Bedingung 1
iZeit = iZeit + iTakt;
dBetrag = dEinheit * iZeit / iTakt;
cout << TAB << TAB << iZeit << "Minuten" << TAB << dBetrag << "Euro";
}

else
{
cout << "Falsche Taste";
iZeit = 0;
dBetrag = 0;
cout << "Programm Startet von Vorne";
goto marke;

}

// cout << NEWLINE; //Desingn
// cout << " Schritt 1 fertig";
// cout << NEWLINE;

//Eingabe 2
cout << TAB << TAB << "Taste: " << TAB;
cin >> cTaste; //Tastenwahl
cout << NEWLINE;

if (cTaste == 'p' || cTaste == 'P')

{
//Bedingung 2
iZeit = iZeit + iTakt;
dBetrag = dEinheit * iZeit / iTakt;
cout << TAB << TAB << iZeit << "Minuten" << TAB << dBetrag << "Euro";
}

else

{
cout << "Falsche Taste";
iZeit = 0;
dBetrag = 0;
cout << "Programm Startet von Vorne";
goto marke;

}

//Parkbeleg drucken

cout << "Bitte die O-Taste Betaetigen";
cin >> cTaste;

if (cTaste == 'o' || cTaste == 'O')

{
cout << iZeit << "Minuten" << NEWLINE;
cout << dBetrag << "Euro" << NEWLINE;
cout << NEWLINE;
cout << "Bitte Warten";
cout << NEWLINE;
cout << "Ihr Parkschein wird gedruckt...";

// cout << NEWLINE; //Desingn
// cout << " Schritt 2 fertig";
// cout << NEWLINE;

cout << "Parkschein wird gedruckt ...";

// {
// cout << "Falsche Taste";
// iZeit = 0; //Resetten
// dBetrag = 0; //Resetten

// }


cout << NEWLINE; //Design

//Eingabe 2
cout << TAB << TAB << "Taste: " << TAB;
cin >> cTaste; //Tastenwah2

if (cTaste == 'p' || cTaste == 'P')
{
//Bedingung 2
iZeit = iZeit + iTakt;
dBetrag = dEinheit * iZeit / iTakt;
cout << TAB << TAB << iZeit << TAB << dBetrag;

}

else (cTaste == 'o' || cTaste == 'O'); //Falsche Bedingung wurde erfüllt

{
cout << "Falsche Taste";
iZeit = 0; //Resetten
dBetrag = 0; //Resetten

}

Sleep (5000); //Warte 5 Sekunden
double d_betrag = 0.0; //Setze Betrag wieder auf 0
int i_zeit = 0; //Setze Zeit wieder auf 0
system ("cls"); //Lösche Screen


getchar();
getchar();
return 0;

}
     
 
what is notes.io
 

Notes.io is a web-based application for taking notes. You can take your notes and share with others people. If you like taking long notes, notes.io is designed for you. To date, over 8,000,000,000 notes created and continuing...

With notes.io;

  • * You can take a note from anywhere and any device with internet connection.
  • * You can share the notes in social platforms (YouTube, Facebook, Twitter, instagram etc.).
  • * You can quickly share your contents without website, blog and e-mail.
  • * You don't need to create any Account to share a note. As you wish you can use quick, easy and best shortened notes with sms, websites, e-mail, or messaging services (WhatsApp, iMessage, Telegram, Signal).
  • * Notes.io has fabulous infrastructure design for a short link and allows you to share the note as an easy and understandable link.

Fast: Notes.io is built for speed and performance. You can take a notes quickly and browse your archive.

Easy: Notes.io doesn’t require installation. Just write and share note!

Short: Notes.io’s url just 8 character. You’ll get shorten link of your note when you want to share. (Ex: notes.io/q )

Free: Notes.io works for 12 years and has been free since the day it was started.


You immediately create your first note and start sharing with the ones you wish. If you want to contact us, you can use the following communication channels;


Email: [email protected]

Twitter: http://twitter.com/notesio

Instagram: http://instagram.com/notes.io

Facebook: http://facebook.com/notesio



Regards;
Notes.io Team

     
 
Shortened Note Link
 
 
Looding Image
 
     
 
Long File
 
 

For written notes was greater than 18KB Unable to shorten.

To be smaller than 18KB, please organize your notes, or sign in.