This commit is contained in:
2024-02-09 23:12:28 +01:00
parent d84ea072ef
commit 5d7694ce0f
11 changed files with 87 additions and 2 deletions

View File

@@ -0,0 +1,31 @@
//
// Created by jordi on 1/8/24.
//
#include <stdio.h>
// Definition der Date-Struktur
struct Date {
int day;
int month;
int year;
};
// Funktion zur Ausgabe des Datums im Format dd.mm.yyyy
void printDate(struct Date *date) {
printf("%02d.%02d.%04d\n", date->day, date->month, date->year);
}
int main() {
// Erstellen eines Date-Objekts und Zuweisen von Werten
struct Date myDate;
myDate.day = 8;
myDate.month = 1;
myDate.year = 2024;
// Aufrufen der Funktion zum Ausgeben des Datums
printf("Das Datum ist: ");
printDate(&myDate);
return 0;
}

View File

@@ -0,0 +1,9 @@
//
// Created by jordi on 1/8/24.
//
#include <stdio.h>
int main()
{
printf("hallo");
}