|
@ -1,15 +1,20 @@ |
|
|
#include <stdio.h> |
|
|
#include <stdio.h> |
|
|
#include "ageinseconds.h" |
|
|
#include "ageinseconds.h" |
|
|
|
|
|
|
|
|
|
|
|
int sekunden(int jahre) { |
|
|
|
|
|
int erg = jahre * 31536000; |
|
|
|
|
|
return erg; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
int run_ageinseconds() { |
|
|
int run_ageinseconds() { |
|
|
int age; |
|
|
int age; |
|
|
|
|
|
|
|
|
printf("Dein Alter: "); |
|
|
printf("Dein Alter: "); |
|
|
scanf("%d", &age); |
|
|
scanf("%d", &age); |
|
|
printf("-------------------------------------------------"); |
|
|
printf("-------------------------------------------------"); |
|
|
printf("\nDu bist: %d Sekunden alt", age * 365 * 24 * 60 * 60); |
|
|
|
|
|
|
|
|
printf("\nDu bist: %d Sekunden alt", sekunden(age)); |
|
|
printf("\n-------------------------------------------------"); |
|
|
printf("\n-------------------------------------------------"); |
|
|
printf("\nDas sind %d in Minuten und %d in Stunden", age * 365 * 24 * 60, age * 365 * 24); |
|
|
printf("\nDas sind %d in Minuten und %d in Stunden", age * 365 * 24 * 60, age * 365 * 24); |
|
|
printf("\n-------------------------------------------------"); |
|
|
printf("\n-------------------------------------------------"); |
|
|
return 0; |
|
|
return 0; |
|
|
} |
|
|
|
|
|
|
|
|
} |