From 089e91af430db23b83b9bb7e0040840d341eaf5a Mon Sep 17 00:00:00 2001 From: Laurin Date: Tue, 6 Feb 2024 13:39:58 +0100 Subject: [PATCH] Implemented interface for main program for conversion of numbers --- src/conversionOfNumbers/main.c | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 src/conversionOfNumbers/main.c diff --git a/src/conversionOfNumbers/main.c b/src/conversionOfNumbers/main.c new file mode 100644 index 0000000..375e414 --- /dev/null +++ b/src/conversionOfNumbers/main.c @@ -0,0 +1,30 @@ +#include "conversionOfNumbers.h" +#include "../userinput.h" +#include + +int main(){ + int min = 0; + int max = 2; + int InputSys; + while(InputSys != 3){ + + printf("\nWaehle Zahlensystem:\n" + "\n<0> Binaer System\n" + "<1> Hexadezimal System\n" + "<2> Beenden\n"); + InputSys = usergetd("\nEingabe: ", &min, &max); + if(InputSys == 2) break; + int InputProg; + + while(InputProg != 3){ + + printf("\nZu oder von einer Dezimalzahl konvertieren?\n" + "\n<0> Zu\n" + "<1> Von\n" + "<2> Hauptmenue\n"); + InputProg = usergetd("\nEingabe: ", &min, &max); + if(InputProg == 2) break; + } + } + return 0; +} \ No newline at end of file