diff --git a/hallo-welt.c b/hallo-welt.c index 30f2e0b..640887b 100644 --- a/hallo-welt.c +++ b/hallo-welt.c @@ -10,7 +10,7 @@ void hallo_welt(void) { printf(HALLO); } // use more then one int type -const char *binaerzahl(uint8_t bin) { +const char *binaerzahl(uint32_t bin) { char *str = malloc(sizeof(bin) * 8 + 1); // Allocate 8 bits for actual data and 1 Bit for the \0 // sign indicating the end of the string @@ -27,8 +27,8 @@ const char *binaerzahl(uint8_t bin) { } int getint(void) { - uint8_t i; - scanf("%hhu", &i); + uint32_t i; + scanf("%u", &i); return i; }