diff --git a/20201210/answer.c b/20201210/answer.c new file mode 100644 index 0000000000000000000000000000000000000000..65a1dc248becb3157f2a226fc7b30df2ffb82e00 --- /dev/null +++ b/20201210/answer.c @@ -0,0 +1,6 @@ +#include "answer.h" + +int answer (void) +{ + return 23; +} diff --git a/20201210/answer.h b/20201210/answer.h new file mode 100644 index 0000000000000000000000000000000000000000..b6777e8210983d315b3ac3424a61bd9c9f0437b1 --- /dev/null +++ b/20201210/answer.h @@ -0,0 +1 @@ +extern int answer (void); diff --git a/20201210/gtk-1.c b/20201210/gtk-1.c new file mode 100644 index 0000000000000000000000000000000000000000..884a14ea528431e54f8391c801958a6e494dfe43 --- /dev/null +++ b/20201210/gtk-1.c @@ -0,0 +1,11 @@ +#include <gtk/gtk.h> + +int main (int argc, char **argv) +{ + gtk_init (&argc, &argv); + GtkWidget *window = gtk_window_new (GTK_WINDOW_TOPLEVEL); + gtk_window_set_title (GTK_WINDOW (window), "Hello"); + gtk_widget_show (window); + gtk_main (); + return 0; +} diff --git a/20201210/gtk-2.c b/20201210/gtk-2.c new file mode 100644 index 0000000000000000000000000000000000000000..c5db19f8d7e859ff12b08ffd6425b84deab35d07 --- /dev/null +++ b/20201210/gtk-2.c @@ -0,0 +1,12 @@ +#include <gtk/gtk.h> + +int main (int argc, char **argv) +{ + gtk_init (&argc, &argv); + GtkWidget *window = gtk_window_new (GTK_WINDOW_TOPLEVEL); + gtk_window_set_title (GTK_WINDOW (window), "Hello"); + g_signal_connect (window, "destroy", G_CALLBACK (gtk_main_quit), NULL); + gtk_widget_show (window); + gtk_main (); + return 0; +} diff --git a/20201210/gtk-3.c b/20201210/gtk-3.c new file mode 100644 index 0000000000000000000000000000000000000000..26fcdd9bf83023b4f3e704a93218134149829f83 --- /dev/null +++ b/20201210/gtk-3.c @@ -0,0 +1,16 @@ +#include <gtk/gtk.h> + +int main (int argc, char **argv) +{ + gtk_init (&argc, &argv); + GtkWidget *window = gtk_window_new (GTK_WINDOW_TOPLEVEL); + gtk_window_set_title (GTK_WINDOW (window), "Hello"); + g_signal_connect (window, "destroy", G_CALLBACK (gtk_main_quit), NULL); + GtkWidget *button = gtk_button_new_with_label ("Quit"); + g_signal_connect (button, "clicked", G_CALLBACK (gtk_main_quit), NULL); + gtk_container_add (GTK_CONTAINER (window), button); + gtk_widget_show (button); + gtk_widget_show (window); + gtk_main (); + return 0; +} diff --git a/20201210/gtk-3a.c b/20201210/gtk-3a.c new file mode 100644 index 0000000000000000000000000000000000000000..a414b65cdf090099634b72b17f1ccde78ec86bcb --- /dev/null +++ b/20201210/gtk-3a.c @@ -0,0 +1,23 @@ +#include <gtk/gtk.h> + +GtkWidget *button; + +void hide_button (void) +{ + gtk_widget_hide (button); +} + +int main (int argc, char **argv) +{ + gtk_init (&argc, &argv); + GtkWidget *window = gtk_window_new (GTK_WINDOW_TOPLEVEL); + gtk_window_set_title (GTK_WINDOW (window), "Hello"); + g_signal_connect (window, "destroy", G_CALLBACK (gtk_main_quit), NULL); + button = gtk_button_new_with_label ("Quit"); + g_signal_connect (button, "clicked", G_CALLBACK (hide_button), NULL); + gtk_container_add (GTK_CONTAINER (window), button); + gtk_widget_show (button); + gtk_widget_show (window); + gtk_main (); + return 0; +} diff --git a/20201210/gtk-3b.c b/20201210/gtk-3b.c new file mode 100644 index 0000000000000000000000000000000000000000..c9e5aa19ca26ba5d2f2d490e21176353fd83000f --- /dev/null +++ b/20201210/gtk-3b.c @@ -0,0 +1,21 @@ +#include <gtk/gtk.h> + +void hide_button (GtkWidget *button) +{ + gtk_widget_hide (button); +} + +int main (int argc, char **argv) +{ + gtk_init (&argc, &argv); + GtkWidget *window = gtk_window_new (GTK_WINDOW_TOPLEVEL); + gtk_window_set_title (GTK_WINDOW (window), "Hello"); + g_signal_connect (window, "destroy", G_CALLBACK (gtk_main_quit), NULL); + GtkWidget *button = gtk_button_new_with_label ("Quit"); + g_signal_connect (button, "clicked", G_CALLBACK (hide_button), button); + gtk_container_add (GTK_CONTAINER (window), button); + gtk_widget_show (button); + gtk_widget_show (window); + gtk_main (); + return 0; +} diff --git a/20201210/gtk-3c.c b/20201210/gtk-3c.c new file mode 100644 index 0000000000000000000000000000000000000000..0c00089967a5575987cd04c89668d8fc6c02bec1 --- /dev/null +++ b/20201210/gtk-3c.c @@ -0,0 +1,16 @@ +#include <gtk/gtk.h> + +int main (int argc, char **argv) +{ + gtk_init (&argc, &argv); + GtkWidget *window = gtk_window_new (GTK_WINDOW_TOPLEVEL); + gtk_window_set_title (GTK_WINDOW (window), "Hello"); + g_signal_connect (window, "destroy", G_CALLBACK (gtk_main_quit), NULL); + GtkWidget *button = gtk_button_new_with_label ("Quit"); + g_signal_connect (button, "clicked", G_CALLBACK (gtk_widget_hide), button); + gtk_container_add (GTK_CONTAINER (window), button); + gtk_widget_show (button); + gtk_widget_show (window); + gtk_main (); + return 0; +} diff --git a/20201210/gtk-4.c b/20201210/gtk-4.c new file mode 100644 index 0000000000000000000000000000000000000000..132dbcb61fb979372da88225e8cb881d2b81a2d4 --- /dev/null +++ b/20201210/gtk-4.c @@ -0,0 +1,26 @@ +#include <gtk/gtk.h> + +int main (int argc, char **argv) +{ + gtk_init (&argc, &argv); + GtkWidget *window = gtk_window_new (GTK_WINDOW_TOPLEVEL); + gtk_window_set_title (GTK_WINDOW (window), "Hello"); + g_signal_connect (window, "destroy", G_CALLBACK (gtk_main_quit), NULL); + + GtkWidget *vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 5); + gtk_container_add (GTK_CONTAINER (window), vbox); + + GtkWidget *button = gtk_button_new_with_label ("Quit"); + g_signal_connect (button, "clicked", G_CALLBACK (gtk_main_quit), NULL); + gtk_container_add (GTK_CONTAINER (vbox), button); + + GtkWidget *drawing_area = gtk_drawing_area_new (); + gtk_container_add (GTK_CONTAINER (vbox), drawing_area); + + gtk_widget_show (drawing_area); + gtk_widget_show (button); + gtk_widget_show (vbox); + gtk_widget_show (window); + gtk_main (); + return 0; +} diff --git a/20201210/gtk-5.c b/20201210/gtk-5.c new file mode 100644 index 0000000000000000000000000000000000000000..c77feaac44766ae3e7b157d3a72e03f62c9c687b --- /dev/null +++ b/20201210/gtk-5.c @@ -0,0 +1,27 @@ +#include <gtk/gtk.h> + +int main (int argc, char **argv) +{ + gtk_init (&argc, &argv); + GtkWidget *window = gtk_window_new (GTK_WINDOW_TOPLEVEL); + gtk_window_set_title (GTK_WINDOW (window), "Hello"); + g_signal_connect (window, "destroy", G_CALLBACK (gtk_main_quit), NULL); + + GtkWidget *vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 5); + gtk_container_add (GTK_CONTAINER (window), vbox); + + GtkWidget *button = gtk_button_new_with_label ("Quit"); + g_signal_connect (button, "clicked", G_CALLBACK (gtk_main_quit), NULL); + gtk_container_add (GTK_CONTAINER (vbox), button); + + GtkWidget *drawing_area = gtk_drawing_area_new (); + gtk_container_add (GTK_CONTAINER (vbox), drawing_area); + gtk_widget_set_size_request (drawing_area, 100, 100); + + gtk_widget_show (drawing_area); + gtk_widget_show (button); + gtk_widget_show (vbox); + gtk_widget_show (window); + gtk_main (); + return 0; +} diff --git a/20201210/gtk-5a.c b/20201210/gtk-5a.c new file mode 100644 index 0000000000000000000000000000000000000000..5386a44255235d40bae6be87c0c9251a8c766fb6 --- /dev/null +++ b/20201210/gtk-5a.c @@ -0,0 +1,27 @@ +#include <gtk/gtk.h> + +int main (int argc, char **argv) +{ + gtk_init (&argc, &argv); + GtkWidget window = gtk_window_new (GTK_WINDOW_TOPLEVEL); + gtk_window_set_title (GTK_WINDOW (window), "Hello"); + g_signal_connect (window, "destroy", G_CALLBACK (gtk_main_quit), NULL); + + GtkWidget vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 5); + gtk_container_add (GTK_CONTAINER (window), vbox); + + GtkWidget button = gtk_button_new_with_label ("Quit"); + g_signal_connect (button, "clicked", G_CALLBACK (gtk_main_quit), NULL); + gtk_container_add (GTK_CONTAINER (vbox), button); + + GtkWidget drawing_area = gtk_drawing_area_new (); + gtk_container_add (GTK_CONTAINER (vbox), drawing_area); + gtk_widget_set_size_request (drawing_area, 100, 100); + + gtk_widget_show (drawing_area); + gtk_widget_show (button); + gtk_widget_show (vbox); + gtk_widget_show (window); + gtk_main (); + return 0; +} diff --git a/20201210/gtk-6.c b/20201210/gtk-6.c new file mode 100644 index 0000000000000000000000000000000000000000..81e12e6958d3c0adbed8d315927104482bc4c681 --- /dev/null +++ b/20201210/gtk-6.c @@ -0,0 +1,53 @@ +#include <gtk/gtk.h> + +gboolean draw (GtkWidget *widget, cairo_t *c, gpointer data) +{ + GdkRGBA red = { 1.0, 0.0, 0.0, 0.8 }; + GdkRGBA yellow = { 1.0, 1.0, 0.0, 0.6 }; + GdkRGBA blue = { 0.0, 0.5, 1.0, 0.4 }; + + gdk_cairo_set_source_rgba (c, &red); + cairo_rectangle (c, 10, 10, 60, 40); + cairo_fill (c); + + gdk_cairo_set_source_rgba (c, &yellow); + cairo_arc (c, 65, 50, 30, 0, 2 * G_PI); + cairo_fill (c); + + gdk_cairo_set_source_rgba (c, &blue); + cairo_move_to (c, 10, 70); + cairo_line_to (c, 70, 70); + cairo_line_to (c, 40, 18); + cairo_close_path (c); + cairo_fill (c); + + return FALSE; /* TRUE to stop other handlers from being invoked for the event. + FALSE to propagate the event further. */ +} + +int main (int argc, char **argv) +{ + gtk_init (&argc, &argv); + GtkWidget *window = gtk_window_new (GTK_WINDOW_TOPLEVEL); + gtk_window_set_title (GTK_WINDOW (window), "Hello"); + g_signal_connect (window, "destroy", G_CALLBACK (gtk_main_quit), NULL); + + GtkWidget *vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 5); + gtk_container_add (GTK_CONTAINER (window), vbox); + + GtkWidget *button = gtk_button_new_with_label ("Quit"); + g_signal_connect (button, "clicked", G_CALLBACK (gtk_main_quit), NULL); + gtk_container_add (GTK_CONTAINER (vbox), button); + + GtkWidget *drawing_area = gtk_drawing_area_new (); + gtk_container_add (GTK_CONTAINER (vbox), drawing_area); + g_signal_connect (drawing_area, "draw", G_CALLBACK (draw), NULL); + gtk_widget_set_size_request (drawing_area, 100, 100); + + gtk_widget_show (drawing_area); + gtk_widget_show (button); + gtk_widget_show (vbox); + gtk_widget_show (window); + gtk_main (); + return 0; +} diff --git a/20201210/gtk-7.c b/20201210/gtk-7.c new file mode 100644 index 0000000000000000000000000000000000000000..11041fbe1d27585ca4edb951f195f114ddad126e --- /dev/null +++ b/20201210/gtk-7.c @@ -0,0 +1,71 @@ +#include <stdio.h> +#include <gtk/gtk.h> + +gboolean draw (GtkWidget *widget, cairo_t *c, gpointer data) +{ + GdkRGBA red = { 1.0, 0.0, 0.0, 0.8 }; + GdkRGBA yellow = { 1.0, 1.0, 0.0, 0.6 }; + GdkRGBA blue = { 0.0, 0.5, 1.0, 0.4 }; + + gdk_cairo_set_source_rgba (c, &red); + cairo_rectangle (c, 10, 10, 60, 40); + cairo_fill (c); + + gdk_cairo_set_source_rgba (c, &yellow); + cairo_arc (c, 65, 50, 30, 0, 2 * G_PI); + cairo_fill (c); + + gdk_cairo_set_source_rgba (c, &blue); + cairo_move_to (c, 10, 70); + cairo_line_to (c, 70, 70); + cairo_line_to (c, 40, 18); + cairo_close_path (c); + cairo_fill (c); + + return FALSE; /* TRUE to stop other handlers from being invoked for the event. + FALSE to propagate the event further. */ +} + +gboolean button_press (GtkWidget *widget, GdkEventButton *e, gpointer data) +{ + printf ("button %d pressed at (%lf, %lf)\n", e->button, e->x, e->y); + return FALSE; +} + +gboolean key_press (GtkWidget *widget, GdkEventKey *e, gpointer data) +{ + printf ("key '%c' (%d) pressed\n", e->keyval, e->keyval); + return FALSE; +} + +int main (int argc, char **argv) +{ + gtk_init (&argc, &argv); + GtkWidget *window = gtk_window_new (GTK_WINDOW_TOPLEVEL); + gtk_window_set_title (GTK_WINDOW (window), "Hello"); + g_signal_connect (window, "destroy", G_CALLBACK (gtk_main_quit), NULL); + + GtkWidget *vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 5); + gtk_container_add (GTK_CONTAINER (window), vbox); + + GtkWidget *button = gtk_button_new_with_label ("Quit"); + g_signal_connect (button, "clicked", G_CALLBACK (gtk_main_quit), NULL); + gtk_container_add (GTK_CONTAINER (vbox), button); + + GtkWidget *drawing_area = gtk_drawing_area_new (); + gtk_container_add (GTK_CONTAINER (vbox), drawing_area); + g_signal_connect (drawing_area, "draw", G_CALLBACK (draw), NULL); + gtk_widget_set_size_request (drawing_area, 100, 100); + gtk_widget_add_events (drawing_area, GDK_BUTTON_PRESS_MASK); + g_signal_connect (drawing_area, "button_press_event", G_CALLBACK (button_press), NULL); + + gtk_widget_add_events (window, GDK_KEY_PRESS_MASK); + g_signal_connect (window, "key_press_event", G_CALLBACK (key_press), NULL); + + gtk_widget_show (drawing_area); + gtk_widget_show (button); + gtk_widget_show (vbox); + gtk_widget_show (window); + gtk_main (); + return 0; +} diff --git a/20201210/gtk-8.c b/20201210/gtk-8.c new file mode 100644 index 0000000000000000000000000000000000000000..80e5747c13d94699d4883018a5b2457fed9885cb --- /dev/null +++ b/20201210/gtk-8.c @@ -0,0 +1,54 @@ +#include <gtk/gtk.h> + +#define WIDTH 320 +#define HEIGHT 240 + +double x = 5; +double y = 95; + +gboolean draw (GtkWidget *widget, cairo_t *c, gpointer data) +{ + GdkRGBA blue = { 0.0, 0.5, 1.0, 1.0 }; + gdk_cairo_set_source_rgba (c, &blue); + cairo_arc (c, x, y, 5, 0, 2 * G_PI); + cairo_fill (c); + return FALSE; +} + +gboolean timer (GtkWidget *widget) +{ + x += 0.5; + y -= 0.7; + gtk_widget_queue_draw_area (widget, 0, 0, WIDTH, HEIGHT); + g_timeout_add (50, (GSourceFunc) timer, widget); + return FALSE; +} + +int main (int argc, char **argv) +{ + gtk_init (&argc, &argv); + GtkWidget *window = gtk_window_new (GTK_WINDOW_TOPLEVEL); + gtk_window_set_title (GTK_WINDOW (window), "Hello"); + g_signal_connect (window, "destroy", G_CALLBACK (gtk_main_quit), NULL); + + GtkWidget *vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 5); + gtk_container_add (GTK_CONTAINER (window), vbox); + + GtkWidget *button = gtk_button_new_with_label ("Quit"); + g_signal_connect (button, "clicked", G_CALLBACK (gtk_main_quit), NULL); + gtk_container_add (GTK_CONTAINER (vbox), button); + + GtkWidget *drawing_area = gtk_drawing_area_new (); + gtk_container_add (GTK_CONTAINER (vbox), drawing_area); + g_signal_connect (drawing_area, "draw", G_CALLBACK (draw), NULL); + gtk_widget_set_size_request (drawing_area, 100, 100); + + g_timeout_add (50, (GSourceFunc) timer, drawing_area); + + gtk_widget_show (drawing_area); + gtk_widget_show (button); + gtk_widget_show (vbox); + gtk_widget_show (window); + gtk_main (); + return 0; +} diff --git a/20201210/hello-1.E b/20201210/hello-1.E new file mode 100644 index 0000000000000000000000000000000000000000..bba2a7fe853f3ead309fa27d02789911adacb2a1 --- /dev/null +++ b/20201210/hello-1.E @@ -0,0 +1,815 @@ +# 1 "hello-1.c" +# 1 "<built-in>" +# 1 "<command-line>" +# 31 "<command-line>" +# 1 "/usr/include/stdc-predef.h" 1 3 4 +# 32 "<command-line>" 2 +# 1 "hello-1.c" +# 1 "/usr/include/stdio.h" 1 3 4 +# 27 "/usr/include/stdio.h" 3 4 +# 1 "/usr/include/x86_64-linux-gnu/bits/libc-header-start.h" 1 3 4 +# 33 "/usr/include/x86_64-linux-gnu/bits/libc-header-start.h" 3 4 +# 1 "/usr/include/features.h" 1 3 4 +# 424 "/usr/include/features.h" 3 4 +# 1 "/usr/include/x86_64-linux-gnu/sys/cdefs.h" 1 3 4 +# 442 "/usr/include/x86_64-linux-gnu/sys/cdefs.h" 3 4 +# 1 "/usr/include/x86_64-linux-gnu/bits/wordsize.h" 1 3 4 +# 443 "/usr/include/x86_64-linux-gnu/sys/cdefs.h" 2 3 4 +# 1 "/usr/include/x86_64-linux-gnu/bits/long-double.h" 1 3 4 +# 444 "/usr/include/x86_64-linux-gnu/sys/cdefs.h" 2 3 4 +# 425 "/usr/include/features.h" 2 3 4 +# 448 "/usr/include/features.h" 3 4 +# 1 "/usr/include/x86_64-linux-gnu/gnu/stubs.h" 1 3 4 +# 10 "/usr/include/x86_64-linux-gnu/gnu/stubs.h" 3 4 +# 1 "/usr/include/x86_64-linux-gnu/gnu/stubs-64.h" 1 3 4 +# 11 "/usr/include/x86_64-linux-gnu/gnu/stubs.h" 2 3 4 +# 449 "/usr/include/features.h" 2 3 4 +# 34 "/usr/include/x86_64-linux-gnu/bits/libc-header-start.h" 2 3 4 +# 28 "/usr/include/stdio.h" 2 3 4 + + + + + +# 1 "/usr/lib/gcc/x86_64-linux-gnu/8/include/stddef.h" 1 3 4 +# 216 "/usr/lib/gcc/x86_64-linux-gnu/8/include/stddef.h" 3 4 + +# 216 "/usr/lib/gcc/x86_64-linux-gnu/8/include/stddef.h" 3 4 +typedef long unsigned int size_t; +# 34 "/usr/include/stdio.h" 2 3 4 + + +# 1 "/usr/lib/gcc/x86_64-linux-gnu/8/include/stdarg.h" 1 3 4 +# 40 "/usr/lib/gcc/x86_64-linux-gnu/8/include/stdarg.h" 3 4 +typedef __builtin_va_list __gnuc_va_list; +# 37 "/usr/include/stdio.h" 2 3 4 + +# 1 "/usr/include/x86_64-linux-gnu/bits/types.h" 1 3 4 +# 27 "/usr/include/x86_64-linux-gnu/bits/types.h" 3 4 +# 1 "/usr/include/x86_64-linux-gnu/bits/wordsize.h" 1 3 4 +# 28 "/usr/include/x86_64-linux-gnu/bits/types.h" 2 3 4 + + +typedef unsigned char __u_char; +typedef unsigned short int __u_short; +typedef unsigned int __u_int; +typedef unsigned long int __u_long; + + +typedef signed char __int8_t; +typedef unsigned char __uint8_t; +typedef signed short int __int16_t; +typedef unsigned short int __uint16_t; +typedef signed int __int32_t; +typedef unsigned int __uint32_t; + +typedef signed long int __int64_t; +typedef unsigned long int __uint64_t; + + + + + + +typedef __int8_t __int_least8_t; +typedef __uint8_t __uint_least8_t; +typedef __int16_t __int_least16_t; +typedef __uint16_t __uint_least16_t; +typedef __int32_t __int_least32_t; +typedef __uint32_t __uint_least32_t; +typedef __int64_t __int_least64_t; +typedef __uint64_t __uint_least64_t; + + + +typedef long int __quad_t; +typedef unsigned long int __u_quad_t; + + + + + + + +typedef long int __intmax_t; +typedef unsigned long int __uintmax_t; +# 140 "/usr/include/x86_64-linux-gnu/bits/types.h" 3 4 +# 1 "/usr/include/x86_64-linux-gnu/bits/typesizes.h" 1 3 4 +# 141 "/usr/include/x86_64-linux-gnu/bits/types.h" 2 3 4 + + +typedef unsigned long int __dev_t; +typedef unsigned int __uid_t; +typedef unsigned int __gid_t; +typedef unsigned long int __ino_t; +typedef unsigned long int __ino64_t; +typedef unsigned int __mode_t; +typedef unsigned long int __nlink_t; +typedef long int __off_t; +typedef long int __off64_t; +typedef int __pid_t; +typedef struct { int __val[2]; } __fsid_t; +typedef long int __clock_t; +typedef unsigned long int __rlim_t; +typedef unsigned long int __rlim64_t; +typedef unsigned int __id_t; +typedef long int __time_t; +typedef unsigned int __useconds_t; +typedef long int __suseconds_t; + +typedef int __daddr_t; +typedef int __key_t; + + +typedef int __clockid_t; + + +typedef void * __timer_t; + + +typedef long int __blksize_t; + + + + +typedef long int __blkcnt_t; +typedef long int __blkcnt64_t; + + +typedef unsigned long int __fsblkcnt_t; +typedef unsigned long int __fsblkcnt64_t; + + +typedef unsigned long int __fsfilcnt_t; +typedef unsigned long int __fsfilcnt64_t; + + +typedef long int __fsword_t; + +typedef long int __ssize_t; + + +typedef long int __syscall_slong_t; + +typedef unsigned long int __syscall_ulong_t; + + + +typedef __off64_t __loff_t; +typedef char *__caddr_t; + + +typedef long int __intptr_t; + + +typedef unsigned int __socklen_t; + + + + +typedef int __sig_atomic_t; +# 39 "/usr/include/stdio.h" 2 3 4 +# 1 "/usr/include/x86_64-linux-gnu/bits/types/__fpos_t.h" 1 3 4 + + + + +# 1 "/usr/include/x86_64-linux-gnu/bits/types/__mbstate_t.h" 1 3 4 +# 13 "/usr/include/x86_64-linux-gnu/bits/types/__mbstate_t.h" 3 4 +typedef struct +{ + int __count; + union + { + unsigned int __wch; + char __wchb[4]; + } __value; +} __mbstate_t; +# 6 "/usr/include/x86_64-linux-gnu/bits/types/__fpos_t.h" 2 3 4 + + + + +typedef struct _G_fpos_t +{ + __off_t __pos; + __mbstate_t __state; +} __fpos_t; +# 40 "/usr/include/stdio.h" 2 3 4 +# 1 "/usr/include/x86_64-linux-gnu/bits/types/__fpos64_t.h" 1 3 4 +# 10 "/usr/include/x86_64-linux-gnu/bits/types/__fpos64_t.h" 3 4 +typedef struct _G_fpos64_t +{ + __off64_t __pos; + __mbstate_t __state; +} __fpos64_t; +# 41 "/usr/include/stdio.h" 2 3 4 +# 1 "/usr/include/x86_64-linux-gnu/bits/types/__FILE.h" 1 3 4 + + + +struct _IO_FILE; +typedef struct _IO_FILE __FILE; +# 42 "/usr/include/stdio.h" 2 3 4 +# 1 "/usr/include/x86_64-linux-gnu/bits/types/FILE.h" 1 3 4 + + + +struct _IO_FILE; + + +typedef struct _IO_FILE FILE; +# 43 "/usr/include/stdio.h" 2 3 4 +# 1 "/usr/include/x86_64-linux-gnu/bits/types/struct_FILE.h" 1 3 4 +# 35 "/usr/include/x86_64-linux-gnu/bits/types/struct_FILE.h" 3 4 +struct _IO_FILE; +struct _IO_marker; +struct _IO_codecvt; +struct _IO_wide_data; + + + + +typedef void _IO_lock_t; + + + + + +struct _IO_FILE +{ + int _flags; + + + char *_IO_read_ptr; + char *_IO_read_end; + char *_IO_read_base; + char *_IO_write_base; + char *_IO_write_ptr; + char *_IO_write_end; + char *_IO_buf_base; + char *_IO_buf_end; + + + char *_IO_save_base; + char *_IO_backup_base; + char *_IO_save_end; + + struct _IO_marker *_markers; + + struct _IO_FILE *_chain; + + int _fileno; + int _flags2; + __off_t _old_offset; + + + unsigned short _cur_column; + signed char _vtable_offset; + char _shortbuf[1]; + + _IO_lock_t *_lock; + + + + + + + + __off64_t _offset; + + struct _IO_codecvt *_codecvt; + struct _IO_wide_data *_wide_data; + struct _IO_FILE *_freeres_list; + void *_freeres_buf; + size_t __pad5; + int _mode; + + char _unused2[15 * sizeof (int) - 4 * sizeof (void *) - sizeof (size_t)]; +}; +# 44 "/usr/include/stdio.h" 2 3 4 +# 52 "/usr/include/stdio.h" 3 4 +typedef __gnuc_va_list va_list; +# 63 "/usr/include/stdio.h" 3 4 +typedef __off_t off_t; +# 77 "/usr/include/stdio.h" 3 4 +typedef __ssize_t ssize_t; + + + + + + +typedef __fpos_t fpos_t; +# 133 "/usr/include/stdio.h" 3 4 +# 1 "/usr/include/x86_64-linux-gnu/bits/stdio_lim.h" 1 3 4 +# 134 "/usr/include/stdio.h" 2 3 4 + + + +extern FILE *stdin; +extern FILE *stdout; +extern FILE *stderr; + + + + + + +extern int remove (const char *__filename) __attribute__ ((__nothrow__ , __leaf__)); + +extern int rename (const char *__old, const char *__new) __attribute__ ((__nothrow__ , __leaf__)); + + + +extern int renameat (int __oldfd, const char *__old, int __newfd, + const char *__new) __attribute__ ((__nothrow__ , __leaf__)); +# 173 "/usr/include/stdio.h" 3 4 +extern FILE *tmpfile (void) ; +# 187 "/usr/include/stdio.h" 3 4 +extern char *tmpnam (char *__s) __attribute__ ((__nothrow__ , __leaf__)) ; + + + + +extern char *tmpnam_r (char *__s) __attribute__ ((__nothrow__ , __leaf__)) ; +# 204 "/usr/include/stdio.h" 3 4 +extern char *tempnam (const char *__dir, const char *__pfx) + __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__malloc__)) ; + + + + + + + +extern int fclose (FILE *__stream); + + + + +extern int fflush (FILE *__stream); +# 227 "/usr/include/stdio.h" 3 4 +extern int fflush_unlocked (FILE *__stream); +# 246 "/usr/include/stdio.h" 3 4 +extern FILE *fopen (const char *__restrict __filename, + const char *__restrict __modes) ; + + + + +extern FILE *freopen (const char *__restrict __filename, + const char *__restrict __modes, + FILE *__restrict __stream) ; +# 279 "/usr/include/stdio.h" 3 4 +extern FILE *fdopen (int __fd, const char *__modes) __attribute__ ((__nothrow__ , __leaf__)) ; +# 292 "/usr/include/stdio.h" 3 4 +extern FILE *fmemopen (void *__s, size_t __len, const char *__modes) + __attribute__ ((__nothrow__ , __leaf__)) ; + + + + +extern FILE *open_memstream (char **__bufloc, size_t *__sizeloc) __attribute__ ((__nothrow__ , __leaf__)) ; + + + + + +extern void setbuf (FILE *__restrict __stream, char *__restrict __buf) __attribute__ ((__nothrow__ , __leaf__)); + + + +extern int setvbuf (FILE *__restrict __stream, char *__restrict __buf, + int __modes, size_t __n) __attribute__ ((__nothrow__ , __leaf__)); + + + + +extern void setbuffer (FILE *__restrict __stream, char *__restrict __buf, + size_t __size) __attribute__ ((__nothrow__ , __leaf__)); + + +extern void setlinebuf (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)); + + + + + + + +extern int fprintf (FILE *__restrict __stream, + const char *__restrict __format, ...); + + + + +extern int printf (const char *__restrict __format, ...); + +extern int sprintf (char *__restrict __s, + const char *__restrict __format, ...) __attribute__ ((__nothrow__)); + + + + + +extern int vfprintf (FILE *__restrict __s, const char *__restrict __format, + __gnuc_va_list __arg); + + + + +extern int vprintf (const char *__restrict __format, __gnuc_va_list __arg); + +extern int vsprintf (char *__restrict __s, const char *__restrict __format, + __gnuc_va_list __arg) __attribute__ ((__nothrow__)); + + + +extern int snprintf (char *__restrict __s, size_t __maxlen, + const char *__restrict __format, ...) + __attribute__ ((__nothrow__)) __attribute__ ((__format__ (__printf__, 3, 4))); + +extern int vsnprintf (char *__restrict __s, size_t __maxlen, + const char *__restrict __format, __gnuc_va_list __arg) + __attribute__ ((__nothrow__)) __attribute__ ((__format__ (__printf__, 3, 0))); +# 379 "/usr/include/stdio.h" 3 4 +extern int vdprintf (int __fd, const char *__restrict __fmt, + __gnuc_va_list __arg) + __attribute__ ((__format__ (__printf__, 2, 0))); +extern int dprintf (int __fd, const char *__restrict __fmt, ...) + __attribute__ ((__format__ (__printf__, 2, 3))); + + + + + + + +extern int fscanf (FILE *__restrict __stream, + const char *__restrict __format, ...) ; + + + + +extern int scanf (const char *__restrict __format, ...) ; + +extern int sscanf (const char *__restrict __s, + const char *__restrict __format, ...) __attribute__ ((__nothrow__ , __leaf__)); +# 409 "/usr/include/stdio.h" 3 4 +extern int fscanf (FILE *__restrict __stream, const char *__restrict __format, ...) __asm__ ("" "__isoc99_fscanf") + + ; +extern int scanf (const char *__restrict __format, ...) __asm__ ("" "__isoc99_scanf") + ; +extern int sscanf (const char *__restrict __s, const char *__restrict __format, ...) __asm__ ("" "__isoc99_sscanf") __attribute__ ((__nothrow__ , __leaf__)) + + ; +# 434 "/usr/include/stdio.h" 3 4 +extern int vfscanf (FILE *__restrict __s, const char *__restrict __format, + __gnuc_va_list __arg) + __attribute__ ((__format__ (__scanf__, 2, 0))) ; + + + + + +extern int vscanf (const char *__restrict __format, __gnuc_va_list __arg) + __attribute__ ((__format__ (__scanf__, 1, 0))) ; + + +extern int vsscanf (const char *__restrict __s, + const char *__restrict __format, __gnuc_va_list __arg) + __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__format__ (__scanf__, 2, 0))); +# 457 "/usr/include/stdio.h" 3 4 +extern int vfscanf (FILE *__restrict __s, const char *__restrict __format, __gnuc_va_list __arg) __asm__ ("" "__isoc99_vfscanf") + + + + __attribute__ ((__format__ (__scanf__, 2, 0))) ; +extern int vscanf (const char *__restrict __format, __gnuc_va_list __arg) __asm__ ("" "__isoc99_vscanf") + + __attribute__ ((__format__ (__scanf__, 1, 0))) ; +extern int vsscanf (const char *__restrict __s, const char *__restrict __format, __gnuc_va_list __arg) __asm__ ("" "__isoc99_vsscanf") __attribute__ ((__nothrow__ , __leaf__)) + + + + __attribute__ ((__format__ (__scanf__, 2, 0))); +# 491 "/usr/include/stdio.h" 3 4 +extern int fgetc (FILE *__stream); +extern int getc (FILE *__stream); + + + + + +extern int getchar (void); + + + + + + +extern int getc_unlocked (FILE *__stream); +extern int getchar_unlocked (void); +# 516 "/usr/include/stdio.h" 3 4 +extern int fgetc_unlocked (FILE *__stream); +# 527 "/usr/include/stdio.h" 3 4 +extern int fputc (int __c, FILE *__stream); +extern int putc (int __c, FILE *__stream); + + + + + +extern int putchar (int __c); +# 543 "/usr/include/stdio.h" 3 4 +extern int fputc_unlocked (int __c, FILE *__stream); + + + + + + + +extern int putc_unlocked (int __c, FILE *__stream); +extern int putchar_unlocked (int __c); + + + + + + +extern int getw (FILE *__stream); + + +extern int putw (int __w, FILE *__stream); + + + + + + + +extern char *fgets (char *__restrict __s, int __n, FILE *__restrict __stream) + ; +# 609 "/usr/include/stdio.h" 3 4 +extern __ssize_t __getdelim (char **__restrict __lineptr, + size_t *__restrict __n, int __delimiter, + FILE *__restrict __stream) ; +extern __ssize_t getdelim (char **__restrict __lineptr, + size_t *__restrict __n, int __delimiter, + FILE *__restrict __stream) ; + + + + + + + +extern __ssize_t getline (char **__restrict __lineptr, + size_t *__restrict __n, + FILE *__restrict __stream) ; + + + + + + + +extern int fputs (const char *__restrict __s, FILE *__restrict __stream); + + + + + +extern int puts (const char *__s); + + + + + + +extern int ungetc (int __c, FILE *__stream); + + + + + + +extern size_t fread (void *__restrict __ptr, size_t __size, + size_t __n, FILE *__restrict __stream) ; + + + + +extern size_t fwrite (const void *__restrict __ptr, size_t __size, + size_t __n, FILE *__restrict __s); +# 679 "/usr/include/stdio.h" 3 4 +extern size_t fread_unlocked (void *__restrict __ptr, size_t __size, + size_t __n, FILE *__restrict __stream) ; +extern size_t fwrite_unlocked (const void *__restrict __ptr, size_t __size, + size_t __n, FILE *__restrict __stream); + + + + + + + +extern int fseek (FILE *__stream, long int __off, int __whence); + + + + +extern long int ftell (FILE *__stream) ; + + + + +extern void rewind (FILE *__stream); +# 713 "/usr/include/stdio.h" 3 4 +extern int fseeko (FILE *__stream, __off_t __off, int __whence); + + + + +extern __off_t ftello (FILE *__stream) ; +# 737 "/usr/include/stdio.h" 3 4 +extern int fgetpos (FILE *__restrict __stream, fpos_t *__restrict __pos); + + + + +extern int fsetpos (FILE *__stream, const fpos_t *__pos); +# 763 "/usr/include/stdio.h" 3 4 +extern void clearerr (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)); + +extern int feof (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)) ; + +extern int ferror (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)) ; + + + +extern void clearerr_unlocked (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)); +extern int feof_unlocked (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)) ; +extern int ferror_unlocked (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)) ; + + + + + + + +extern void perror (const char *__s); + + + + + +# 1 "/usr/include/x86_64-linux-gnu/bits/sys_errlist.h" 1 3 4 +# 26 "/usr/include/x86_64-linux-gnu/bits/sys_errlist.h" 3 4 +extern int sys_nerr; +extern const char *const sys_errlist[]; +# 788 "/usr/include/stdio.h" 2 3 4 + + + + +extern int fileno (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)) ; + + + + +extern int fileno_unlocked (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)) ; +# 806 "/usr/include/stdio.h" 3 4 +extern FILE *popen (const char *__command, const char *__modes) ; + + + + + +extern int pclose (FILE *__stream); + + + + + +extern char *ctermid (char *__s) __attribute__ ((__nothrow__ , __leaf__)); +# 846 "/usr/include/stdio.h" 3 4 +extern void flockfile (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)); + + + +extern int ftrylockfile (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)) ; + + +extern void funlockfile (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)); +# 864 "/usr/include/stdio.h" 3 4 +extern int __uflow (FILE *); +extern int __overflow (FILE *, int); + + + + +# 1 "/usr/include/x86_64-linux-gnu/bits/stdio.h" 1 3 4 +# 38 "/usr/include/x86_64-linux-gnu/bits/stdio.h" 3 4 +extern __inline __attribute__ ((__gnu_inline__)) int +vprintf (const char *__restrict __fmt, __gnuc_va_list __arg) +{ + return vfprintf (stdout, __fmt, __arg); +} + + + +extern __inline __attribute__ ((__gnu_inline__)) int +getchar (void) +{ + return getc (stdin); +} + + + + +extern __inline __attribute__ ((__gnu_inline__)) int +fgetc_unlocked (FILE *__fp) +{ + return (__builtin_expect (((__fp)->_IO_read_ptr >= (__fp)->_IO_read_end), 0) ? __uflow (__fp) : *(unsigned char *) (__fp)->_IO_read_ptr++); +} + + + + + +extern __inline __attribute__ ((__gnu_inline__)) int +getc_unlocked (FILE *__fp) +{ + return (__builtin_expect (((__fp)->_IO_read_ptr >= (__fp)->_IO_read_end), 0) ? __uflow (__fp) : *(unsigned char *) (__fp)->_IO_read_ptr++); +} + + +extern __inline __attribute__ ((__gnu_inline__)) int +getchar_unlocked (void) +{ + return (__builtin_expect (((stdin)->_IO_read_ptr >= (stdin)->_IO_read_end), 0) ? __uflow (stdin) : *(unsigned char *) (stdin)->_IO_read_ptr++); +} + + + + +extern __inline __attribute__ ((__gnu_inline__)) int +putchar (int __c) +{ + return putc (__c, stdout); +} + + + + +extern __inline __attribute__ ((__gnu_inline__)) int +fputc_unlocked (int __c, FILE *__stream) +{ + return (__builtin_expect (((__stream)->_IO_write_ptr >= (__stream)->_IO_write_end), 0) ? __overflow (__stream, (unsigned char) (__c)) : (unsigned char) (*(__stream)->_IO_write_ptr++ = (__c))); +} + + + + + +extern __inline __attribute__ ((__gnu_inline__)) int +putc_unlocked (int __c, FILE *__stream) +{ + return (__builtin_expect (((__stream)->_IO_write_ptr >= (__stream)->_IO_write_end), 0) ? __overflow (__stream, (unsigned char) (__c)) : (unsigned char) (*(__stream)->_IO_write_ptr++ = (__c))); +} + + +extern __inline __attribute__ ((__gnu_inline__)) int +putchar_unlocked (int __c) +{ + return (__builtin_expect (((stdout)->_IO_write_ptr >= (stdout)->_IO_write_end), 0) ? __overflow (stdout, (unsigned char) (__c)) : (unsigned char) (*(stdout)->_IO_write_ptr++ = (__c))); +} +# 127 "/usr/include/x86_64-linux-gnu/bits/stdio.h" 3 4 +extern __inline __attribute__ ((__gnu_inline__)) int +__attribute__ ((__nothrow__ , __leaf__)) feof_unlocked (FILE *__stream) +{ + return (((__stream)->_flags & 0x0010) != 0); +} + + +extern __inline __attribute__ ((__gnu_inline__)) int +__attribute__ ((__nothrow__ , __leaf__)) ferror_unlocked (FILE *__stream) +{ + return (((__stream)->_flags & 0x0020) != 0); +} +# 871 "/usr/include/stdio.h" 2 3 4 +# 879 "/usr/include/stdio.h" 3 4 + +# 2 "hello-1.c" 2 + + +# 3 "hello-1.c" +int main (void) +{ + printf ("Hello, world!\n"); + return 0; +} diff --git a/20201210/hello-1.c b/20201210/hello-1.c new file mode 100644 index 0000000000000000000000000000000000000000..b19d80e9bd0bd7c5ed8f54b20c6a50d9166f03ac --- /dev/null +++ b/20201210/hello-1.c @@ -0,0 +1,7 @@ +#include <stdio.h> + +int main (void) +{ + printf ("Hello, world!\n"); + return 0; +} diff --git a/20201210/hello-2.c b/20201210/hello-2.c new file mode 100644 index 0000000000000000000000000000000000000000..1f2dbb2b8aa8984b4401f3f8425662a0171184c1 --- /dev/null +++ b/20201210/hello-2.c @@ -0,0 +1,5 @@ +int main (void) +{ + printf ("Hello, world!\n"); + return 0; +} diff --git a/20201210/hello-3.c b/20201210/hello-3.c new file mode 100644 index 0000000000000000000000000000000000000000..304452b8c501faf03fbd0afaa267e6ef0172807e --- /dev/null +++ b/20201210/hello-3.c @@ -0,0 +1,7 @@ +extern int printf (const char *__restrict __format, ...); + +int main (void) +{ + printf ("Hello, world!\n"); + return 0; +} diff --git a/20201210/hello-gtk.c b/20201210/hello-gtk.c new file mode 100644 index 0000000000000000000000000000000000000000..016867d41e42de57390a21653de467c061e5ded0 --- /dev/null +++ b/20201210/hello-gtk.c @@ -0,0 +1,23 @@ +#include <gtk/gtk.h> + +int main (int argc, char **argv) +{ + gtk_init (&argc, &argv); + GtkWidget *window = gtk_window_new (GTK_WINDOW_TOPLEVEL); + gtk_window_set_title (GTK_WINDOW (window), "Hello"); + g_signal_connect (window, "destroy", G_CALLBACK (gtk_main_quit), NULL); + GtkWidget *vbox = gtk_box_new (GTK_ORIENTATION_VERTICAL, 5); + gtk_container_add (GTK_CONTAINER (window), vbox); + gtk_container_set_border_width (GTK_CONTAINER (vbox), 10); + GtkWidget *label = gtk_label_new ("Hello, world!"); + gtk_container_add (GTK_CONTAINER (vbox), label); + GtkWidget *button = gtk_button_new_with_label ("Quit"); + g_signal_connect (button, "clicked", G_CALLBACK (gtk_main_quit), NULL); + gtk_container_add (GTK_CONTAINER (vbox), button); + gtk_widget_show (button); + gtk_widget_show (label); + gtk_widget_show (vbox); + gtk_widget_show (window); + gtk_main (); + return 0; +} diff --git a/20201210/hexe.h b/20201210/hexe.h new file mode 100644 index 0000000000000000000000000000000000000000..2b98e2bb0231a5114084d64430290fea93281edc --- /dev/null +++ b/20201210/hexe.h @@ -0,0 +1 @@ +eine kleine Hexe. diff --git a/20201210/higher-math-1.c b/20201210/higher-math-1.c new file mode 100644 index 0000000000000000000000000000000000000000..8bd228547b9dde9c5df71c45330df591b5fb593d --- /dev/null +++ b/20201210/higher-math-1.c @@ -0,0 +1,8 @@ +#include <stdio.h> + +#define VIER 4 + +int main (void) +{ + printf ("3 * 4 = %d\n", 3 * VIER); +} diff --git a/20201210/higher-math-2.c b/20201210/higher-math-2.c new file mode 100644 index 0000000000000000000000000000000000000000..784c63b156f8881bec9133910c7fe6c524b3004c --- /dev/null +++ b/20201210/higher-math-2.c @@ -0,0 +1,11 @@ +#include <stdio.h> + +#define N 4 + +int prime[N] = { 2, 3, 5, 7 }; + +int main (void) +{ + for (int i = 0; i < N; i++) + printf ("prime[%d] = %d\n", i, prime[i]); +} diff --git a/20201210/higher-math-3.c b/20201210/higher-math-3.c new file mode 100644 index 0000000000000000000000000000000000000000..4292be39ab64d0dd538f533ba82a3a4cdf0a046c --- /dev/null +++ b/20201210/higher-math-3.c @@ -0,0 +1,8 @@ +#include <stdio.h> + +#define VIER 4; + +int main (void) +{ + printf ("3 * 4 = %d\n", 3 * VIER); +} diff --git a/20201210/higher-math-4.c b/20201210/higher-math-4.c new file mode 100644 index 0000000000000000000000000000000000000000..99edb16ca410f6a10ae8b8c65c5b6bb9c80146e2 --- /dev/null +++ b/20201210/higher-math-4.c @@ -0,0 +1,8 @@ +#include <stdio.h> + +#define VIER 2 + 2 + +int main (void) +{ + printf ("3 * 4 = %d\n", 3 * VIER); +} diff --git a/20201210/higher-math-5.c b/20201210/higher-math-5.c new file mode 100644 index 0000000000000000000000000000000000000000..3eba14e088add18642af9e3bd810a57460d88729 --- /dev/null +++ b/20201210/higher-math-5.c @@ -0,0 +1,8 @@ +#include <stdio.h> + +#define VIER (2 + 2) + +int main (void) +{ + printf ("3 * 4 = %d\n", 3 * VIER); +} diff --git a/20201210/hp-20201210.pdf b/20201210/hp-20201210.pdf index 1cdccee96eaf935b0977fe801f9da0bb84478945..f953230f19ab3cd0678eacb4d6ee9b102decc220 100644 Binary files a/20201210/hp-20201210.pdf and b/20201210/hp-20201210.pdf differ diff --git a/20201210/hp-20201210.tex b/20201210/hp-20201210.tex index b5fe31c4d208a477e31a9c509ddc183c5f0eaa42..f0a92cd7a43744436b67af0486d133f5e85e7fbf 100644 --- a/20201210/hp-20201210.tex +++ b/20201210/hp-20201210.tex @@ -675,14 +675,14 @@ ibpng16 -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux -gnu/glib-2.0/include -lgtk-3 -lgdk-3 -lpangocairo-1.0 -lpango-1.0 -latk-1.0 -lcairo-gobject -lcairo -lgdk_pix - buf-2.0 -lgio-2.0 -lgobject-2.0 -lglib-2.0-o hello-gtk¿ + buf-2.0 -lgio-2.0 -lgobject-2.0 -lglib-2.0 -o hello-gtk¿ \end{lstlisting} \vspace*{-2cm} \end{onlyenv} \begin{onlyenv}<5-> \begin{lstlisting}[style=terminal,gobble=10] - $ ¡gcc -Wall -O hello-gtk.c $(pkg-config --cflags --libs) - -o hello-gtk¿ + $ ¡gcc -Wall -O hello-gtk.c $(pkg-config --cflags --libs + gtk+-3.0 -o hello-gtk¿ \end{lstlisting} \end{onlyenv} \begin{onlyenv}<5> @@ -702,8 +702,8 @@ \item Auf manchen Plattformen kommt es auf die Reihenfolge an: \begin{lstlisting}[style=terminal,gobble=8] - $ ¡gcc -Wall -O $(pkg-config --cflags) \ - hello-gtk.c $(pkg-config --libs) \ + $ ¡gcc -Wall -O $(pkg-config --cflags gtk+-3.0) \ + hello-gtk.c $(pkg-config --libs gtk+-3.0) \ -o hello-gtk¿ \end{lstlisting} (Backslash = "`Es geht in der nächsten Zeile weiter."') @@ -808,6 +808,8 @@ \end{frame} +\iffalse + \section{Algorithmen} \subsection{Differentialgleichungen} @@ -1008,8 +1010,6 @@ \end{frame} -\iffalse - \nosectionnonumber{\inserttitle} \begin{frame} diff --git a/20201210/maerchen.c b/20201210/maerchen.c new file mode 100644 index 0000000000000000000000000000000000000000..5c2716e85205136d406ad2e20285c18ddc967c07 --- /dev/null +++ b/20201210/maerchen.c @@ -0,0 +1,4 @@ +Vor langer, langer Zeit +gab es einmal +#include "hexe.h" +Die lebte in einem Wald. diff --git a/20201210/philosophy-2.c b/20201210/philosophy-2.c new file mode 100644 index 0000000000000000000000000000000000000000..0e02bd4bb3ffc61a3371932ab17ad36fa5a2c507 --- /dev/null +++ b/20201210/philosophy-2.c @@ -0,0 +1,8 @@ +#include <stdio.h> +#include <answer.h> + +int main (void) +{ + printf ("The answer is %d.\n", answer ()); + return 0; +} diff --git a/20201210/philosophy-3.c b/20201210/philosophy-3.c new file mode 100644 index 0000000000000000000000000000000000000000..c104bc5a96f892831c0c51daeea2ae2ad4b21f8c --- /dev/null +++ b/20201210/philosophy-3.c @@ -0,0 +1,7 @@ +#include <stdio.h> + +int main (void) +{ + printf ("The answer is %d.\n", answer ()); + return 0; +} diff --git a/20201210/philosophy-4.c b/20201210/philosophy-4.c new file mode 100644 index 0000000000000000000000000000000000000000..990eebf41e6438223558da8d528646fb78bbbaac --- /dev/null +++ b/20201210/philosophy-4.c @@ -0,0 +1,8 @@ +#include <stdio.h> +#include "answer.c" + +int main (void) +{ + printf ("The answer is %d.\n", answer ()); + return 0; +} diff --git a/20201210/philosophy.c b/20201210/philosophy.c new file mode 100644 index 0000000000000000000000000000000000000000..e9f508a501d9ec66d02e0636a9f6c71f2c7a8594 --- /dev/null +++ b/20201210/philosophy.c @@ -0,0 +1,8 @@ +#include <stdio.h> +#include "answer.h" + +int main (void) +{ + printf ("The answer is %d.\n", answer ()); + return 0; +} diff --git a/hp-slides-2020ws.pdf b/hp-slides-2020ws.pdf index 8757f7216e88790e04879bbfb20d1a7cdf6880eb..a0f4265a16fba411e21cb081b541eac4c8d2fe15 100644 Binary files a/hp-slides-2020ws.pdf and b/hp-slides-2020ws.pdf differ