From ea45391160421f04ae3beace164df98d3262553f Mon Sep 17 00:00:00 2001
From: Peter Gerwinski <peter.gerwinski@hs-bochum.de>
Date: Thu, 3 Dec 2020 19:10:00 +0100
Subject: [PATCH] weitere Beispiel-Programme 3.12.2020

---
 20201112/fibonacci.txt          | 60 ++++++++++++++++++++++++++++
 20201112/loesung-3-10.c         | 15 +++++++
 20201112/loesung-3-11.c         | 15 +++++++
 20201112/loesung-3-12.c         | 15 +++++++
 20201112/loesung-3-3.c          | 15 +++++++
 20201112/loesung-3-4.c          | 15 +++++++
 20201112/loesung-3-5.c          | 15 +++++++
 20201112/loesung-3-6.c          | 16 ++++++++
 20201112/loesung-3-7.c          | 15 +++++++
 20201112/loesung-3-8.c          | 15 +++++++
 20201112/loesung-3-9.c          | 15 +++++++
 20201112/test.txt               |  6 +++
 20201203/fibonacci-1.c          | 15 +++++++
 20201203/fibonacci-10.c         | 56 ++++++++++++++++++++++++++
 20201203/fibonacci-11.c         | 56 ++++++++++++++++++++++++++
 20201203/fibonacci-2.c          | 21 ++++++++++
 20201203/fibonacci-3.c          | 23 +++++++++++
 20201203/fibonacci-4.c          | 31 ++++++++++++++
 20201203/fibonacci-5.c          | 31 ++++++++++++++
 20201203/fibonacci-6.c          | 45 +++++++++++++++++++++
 20201203/fibonacci-7.c          | 47 ++++++++++++++++++++++
 20201203/fibonacci-8.c          | 71 +++++++++++++++++++++++++++++++++
 20201203/fibonacci-9.c          | 56 ++++++++++++++++++++++++++
 20201203/integers-1.c           |  9 +++++
 20201203/integers-2.c           |  9 +++++
 20201203/integers-2.s           | 26 ++++++++++++
 20201203/setup-loop-1.c         | 16 ++++++++
 20201203/setup-loop-2.c         | 19 +++++++++
 20201203/string-operations-1.c  | 21 ++++++++++
 20201203/string-operations-10.c | 31 ++++++++++++++
 20201203/string-operations-11.c | 20 ++++++++++
 20201203/string-operations-12.c | 20 ++++++++++
 20201203/string-operations-13.c | 20 ++++++++++
 20201203/string-operations-14.c | 21 ++++++++++
 20201203/string-operations-15.c | 21 ++++++++++
 20201203/string-operations-16.c | 17 ++++++++
 20201203/string-operations-17.c | 17 ++++++++
 20201203/string-operations-18.c | 17 ++++++++
 20201203/string-operations-19.c | 15 +++++++
 20201203/string-operations-2.c  | 23 +++++++++++
 20201203/string-operations-3.c  | 23 +++++++++++
 20201203/string-operations-4.c  | 23 +++++++++++
 20201203/string-operations-5.c  | 21 ++++++++++
 20201203/string-operations-6.c  | 20 ++++++++++
 20201203/string-operations-7.c  | 20 ++++++++++
 20201203/string-operations-8.c  | 27 +++++++++++++
 20201203/string-operations-8.s  | 65 ++++++++++++++++++++++++++++++
 20201203/string-operations-9.c  | 27 +++++++++++++
 20201203/string-operations-9.s  | 65 ++++++++++++++++++++++++++++++
 49 files changed, 1282 insertions(+)
 create mode 100644 20201112/fibonacci.txt
 create mode 100644 20201112/loesung-3-10.c
 create mode 100644 20201112/loesung-3-11.c
 create mode 100644 20201112/loesung-3-12.c
 create mode 100644 20201112/loesung-3-3.c
 create mode 100644 20201112/loesung-3-4.c
 create mode 100644 20201112/loesung-3-5.c
 create mode 100644 20201112/loesung-3-6.c
 create mode 100644 20201112/loesung-3-7.c
 create mode 100644 20201112/loesung-3-8.c
 create mode 100644 20201112/loesung-3-9.c
 create mode 100644 20201112/test.txt
 create mode 100644 20201203/fibonacci-1.c
 create mode 100644 20201203/fibonacci-10.c
 create mode 100644 20201203/fibonacci-11.c
 create mode 100644 20201203/fibonacci-2.c
 create mode 100644 20201203/fibonacci-3.c
 create mode 100644 20201203/fibonacci-4.c
 create mode 100644 20201203/fibonacci-5.c
 create mode 100644 20201203/fibonacci-6.c
 create mode 100644 20201203/fibonacci-7.c
 create mode 100644 20201203/fibonacci-8.c
 create mode 100644 20201203/fibonacci-9.c
 create mode 100644 20201203/integers-1.c
 create mode 100644 20201203/integers-2.c
 create mode 100644 20201203/integers-2.s
 create mode 100644 20201203/setup-loop-1.c
 create mode 100644 20201203/setup-loop-2.c
 create mode 100644 20201203/string-operations-1.c
 create mode 100644 20201203/string-operations-10.c
 create mode 100644 20201203/string-operations-11.c
 create mode 100644 20201203/string-operations-12.c
 create mode 100644 20201203/string-operations-13.c
 create mode 100644 20201203/string-operations-14.c
 create mode 100644 20201203/string-operations-15.c
 create mode 100644 20201203/string-operations-16.c
 create mode 100644 20201203/string-operations-17.c
 create mode 100644 20201203/string-operations-18.c
 create mode 100644 20201203/string-operations-19.c
 create mode 100644 20201203/string-operations-2.c
 create mode 100644 20201203/string-operations-3.c
 create mode 100644 20201203/string-operations-4.c
 create mode 100644 20201203/string-operations-5.c
 create mode 100644 20201203/string-operations-6.c
 create mode 100644 20201203/string-operations-7.c
 create mode 100644 20201203/string-operations-8.c
 create mode 100644 20201203/string-operations-8.s
 create mode 100644 20201203/string-operations-9.c
 create mode 100644 20201203/string-operations-9.s

diff --git a/20201112/fibonacci.txt b/20201112/fibonacci.txt
new file mode 100644
index 0000000..d2daea9
--- /dev/null
+++ b/20201112/fibonacci.txt
@@ -0,0 +1,60 @@
+Fibonacci-Zahl Nr. 199:
+
+ * Quelle: http://www.wackerart.de/mathematik/big_numbers/fibonacci_numbers.html
+   173 402 521 172 797 813 159 685 037 284 371 942 044 301
+
+ * Quelle: Wolfram Alpha
+   173 402 521 172 797 813 159 685 037 284 371 942 044 301
+ 
+ * Quelle: ./loesung-3-12
+   173 402 521 172 797 813 134 481 939 662 687 621 349 376
+                            ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+Ab loesung-3-7.c ist die Berechnung der Fibonacci-Zahlen falsch!
+                                                         ~~~~~~
+Derartige Rechnungen darf man nur mit ganzen Zahlen durchführen,
+nicht jedoch mit Fließkommazahlen.
+
+Dies gilt insbesondere auch für Kryptographie, z.B. RSA-Verschlüsselung.
+
+
+Die Fibonacci-Zahl Nr. 199 paßt selbst in eine "long long unsigned" nicht hinein.
+
+Wie kann man die Genauigkeit des Rechners erhöhen?
+--> "schriftlich" rechnen
+
+  13 · 17 = (10 + 3) · (10 + 7)
+
+          = 10 · 10 + 10 · 7 + 3 · 10 + 3 · 7    --> nur noch kleines Einmaleins,
+                                                     evtl. mit Nullen dran
+          =    100
+             +  70
+             +  30
+             +  21
+            ---1--
+               221
+
+--> Funktion, um 2 128-Bit-Zahlen zu addieren
+
+ - Wir speichern jede 128-Bit-Zahl in einem Array von 4 32-Bit-Zahlen
+
+ - Wir addieren jeweils 2 32-Bit-Zahlen ("1 Ziffer").
+   Das Ergebnis kann größer sein als 32 Bit, aber nicht größer als 64 Bit.
+
+ - Die unteren 32 Bit speichern wir als Ergebnis (7 + 5: "2 hin").
+   Die oberen merken wir uns als Übertrag ("1 im Sinn").
+
+ - Damit haben wir den "Einer" addiert.
+   Als nächstes kommt der "Zehner" (tatsächlich: der 2^32er).
+   --> Wir gehen das Array in einer Schleife von rechts nach links durch.
+
+Weniger effizient, aber leichter auszugeben: Dezimalziffern als Array speichern.
+--> siehe ../20201203/fibonacci-*.c
+
+ * Quelle: ../20201203/fibonacci-10.c
+   173 402 521 172 797 813 159 685 037 284 371 942 044 301
+
+--> :-)
+
+f[9999] = 20793608237133498072112648988642836825087036094015903119682945866528501423455686648927456034305226515591757343297190158010624794267250973176133810179902738038231789748346235556483191431591924532394420028067810320408724414693462849062668387083308048250920654493340878733226377580847446324873797603734794648258113858631550404081017260381202919943892370942852601647398213554479081823593715429566945149312993664846779090437799284773675379284270660175134664833266377698642012106891355791141872776934080803504956794094648292880566056364718187662668970758537383352677420835574155945658542003634765324541006121012446785689171494803262408602693091211601973938229446636049901531963286159699077880427720289235539329671877182915643419079186525118678856821600897520171070499437657067342400871083908811800976259727431820539554256869460815355918458253398234382360435762759823179896116748424269545924633204614137992850814352018738480923581553988990897151469406131695614497783720743461373756218685106856826090696339815490921253714537241866911604250597353747823733268178182198509240226955826416016690084749816072843582488613184829905383150180047844353751554201573833105521980998123833253261228689824051777846588461079790807828367132384798451794011076569057522158680378961532160858387223882974380483931929541222100800313580688585002598879566463221427820448492565073106595808837401648996423563386109782045634122467872921845606409174360635618216883812562321664442822952537577492715365321134204530686742435454505103269768144370118494906390254934942358904031509877369722437053383165360388595116980245927935225901537634925654872380877183008301074569444002426436414756905094535072804764684492105680024739914490555904391369218696387092918189246157103450387050229300603241611410707453960080170928277951834763216705242485820801423866526633816082921442883095463259080471819329201710147828025221385656340207489796317663278872207607791034431700112753558813478888727503825389066823098683355695718137867882982111710796422706778536913192342733364556727928018953989153106047379741280794091639429908796650294603536651238230626
+(2090 Ziffern)
diff --git a/20201112/loesung-3-10.c b/20201112/loesung-3-10.c
new file mode 100644
index 0000000..7bb464e
--- /dev/null
+++ b/20201112/loesung-3-10.c
@@ -0,0 +1,15 @@
+#include <stdio.h>
+
+int main (void)
+{
+  long double f0 = 0;
+  long double f1 = 1;
+  for (int i = 0; i < 200; i++)
+    {
+      printf ("f[%d] = %.0Lf\n", i, f0);
+      long double f2 = f0 + f1;
+      f0 = f1;
+      f1 = f2;
+    }
+  return 0;
+}
diff --git a/20201112/loesung-3-11.c b/20201112/loesung-3-11.c
new file mode 100644
index 0000000..def1256
--- /dev/null
+++ b/20201112/loesung-3-11.c
@@ -0,0 +1,15 @@
+#include <stdio.h>
+
+int main (void)
+{
+  long double f0 = 0;
+  long double f1 = 1;
+  for (int i = 0; i < 200; i++)
+    {
+      printf ("f[%d] = %30.0Lf\n", i, f0);
+      long double f2 = f0 + f1;
+      f0 = f1;
+      f1 = f2;
+    }
+  return 0;
+}
diff --git a/20201112/loesung-3-12.c b/20201112/loesung-3-12.c
new file mode 100644
index 0000000..7ca8986
--- /dev/null
+++ b/20201112/loesung-3-12.c
@@ -0,0 +1,15 @@
+#include <stdio.h>
+
+int main (void)
+{
+  long double f0 = 0;
+  long double f1 = 1;
+  for (int i = 0; i < 200; i++)
+    {
+      printf ("f[%3d] = %60.0Lf\n", i, f0);
+      long double f2 = f0 + f1;
+      f0 = f1;
+      f1 = f2;
+    }
+  return 0;
+}
diff --git a/20201112/loesung-3-3.c b/20201112/loesung-3-3.c
new file mode 100644
index 0000000..c469857
--- /dev/null
+++ b/20201112/loesung-3-3.c
@@ -0,0 +1,15 @@
+#include <stdio.h>
+
+int main (void)
+{
+  long int f0 = 0;
+  long int f1 = 1;
+  for (int i = 0; i < 50; i++)
+    {
+      printf ("f[%d] = %d\n", i, f0);
+      int f2 = f0 + f1;
+      f0 = f1;
+      f1 = f2;
+    }
+  return 0;
+}
diff --git a/20201112/loesung-3-4.c b/20201112/loesung-3-4.c
new file mode 100644
index 0000000..c3c0dbe
--- /dev/null
+++ b/20201112/loesung-3-4.c
@@ -0,0 +1,15 @@
+#include <stdio.h>
+
+int main (void)
+{
+  long int f0 = 0;
+  long int f1 = 1;
+  for (int i = 0; i < 50; i++)
+    {
+      printf ("f[%d] = %ld\n", i, f0);
+      long int f2 = f0 + f1;
+      f0 = f1;
+      f1 = f2;
+    }
+  return 0;
+}
diff --git a/20201112/loesung-3-5.c b/20201112/loesung-3-5.c
new file mode 100644
index 0000000..1191255
--- /dev/null
+++ b/20201112/loesung-3-5.c
@@ -0,0 +1,15 @@
+#include <stdio.h>
+
+int main (void)
+{
+  long f0 = 0;
+  long f1 = 1;
+  for (int i = 0; i < 50; i++)
+    {
+      printf ("f[%d] = %ld\n", i, f0);
+      long f2 = f0 + f1;
+      f0 = f1;
+      f1 = f2;
+    }
+  return 0;
+}
diff --git a/20201112/loesung-3-6.c b/20201112/loesung-3-6.c
new file mode 100644
index 0000000..339217e
--- /dev/null
+++ b/20201112/loesung-3-6.c
@@ -0,0 +1,16 @@
+#include <stdio.h>
+#include <stdint.h>
+
+int main (void)
+{
+  uint64_t f0 = 0;
+  uint64_t f1 = 1;
+  for (int i = 0; i < 100; i++)
+    {
+      printf ("f[%d] = %lu\n", i, f0);
+      uint64_t f2 = f0 + f1;
+      f0 = f1;
+      f1 = f2;
+    }
+  return 0;
+}
diff --git a/20201112/loesung-3-7.c b/20201112/loesung-3-7.c
new file mode 100644
index 0000000..11a9e20
--- /dev/null
+++ b/20201112/loesung-3-7.c
@@ -0,0 +1,15 @@
+#include <stdio.h>
+
+int main (void)
+{
+  long double f0 = 0;
+  long double f1 = 1;
+  for (int i = 0; i < 100; i++)
+    {
+      printf ("f[%d] = %llf\n", i, f0);
+      long double f2 = f0 + f1;
+      f0 = f1;
+      f1 = f2;
+    }
+  return 0;
+}
diff --git a/20201112/loesung-3-8.c b/20201112/loesung-3-8.c
new file mode 100644
index 0000000..d6aff68
--- /dev/null
+++ b/20201112/loesung-3-8.c
@@ -0,0 +1,15 @@
+#include <stdio.h>
+
+int main (void)
+{
+  long double f0 = 0;
+  long double f1 = 1;
+  for (int i = 0; i < 100; i++)
+    {
+      printf ("f[%d] = %Lf\n", i, f0);
+      long double f2 = f0 + f1;
+      f0 = f1;
+      f1 = f2;
+    }
+  return 0;
+}
diff --git a/20201112/loesung-3-9.c b/20201112/loesung-3-9.c
new file mode 100644
index 0000000..e1d95dc
--- /dev/null
+++ b/20201112/loesung-3-9.c
@@ -0,0 +1,15 @@
+#include <stdio.h>
+
+int main (void)
+{
+  long double f0 = 0;
+  long double f1 = 1;
+  for (int i = 0; i < 100; i++)
+    {
+      printf ("f[%d] = %.0Lf\n", i, f0);
+      long double f2 = f0 + f1;
+      f0 = f1;
+      f1 = f2;
+    }
+  return 0;
+}
diff --git a/20201112/test.txt b/20201112/test.txt
new file mode 100644
index 0000000..f43a184
--- /dev/null
+++ b/20201112/test.txt
@@ -0,0 +1,6 @@
+Ich ging im Walde
+so für mich hin,
+und nichts zu suchen,
+das war mein Sinn.
+
+vim ist praktisch.
diff --git a/20201203/fibonacci-1.c b/20201203/fibonacci-1.c
new file mode 100644
index 0000000..ec5f4d9
--- /dev/null
+++ b/20201203/fibonacci-1.c
@@ -0,0 +1,15 @@
+#include <stdio.h>
+
+int main (void)
+{
+  int f0 = 0;
+  int f1 = 1;
+  for (int i = 0; i < 50; i++)
+    {
+      printf ("f[%d] = %d\n", i, f0);
+      int f2 = f0 + f1;
+      f0 = f1;
+      f1 = f2;
+    }
+  return 0;
+}
diff --git a/20201203/fibonacci-10.c b/20201203/fibonacci-10.c
new file mode 100644
index 0000000..5f5da72
--- /dev/null
+++ b/20201203/fibonacci-10.c
@@ -0,0 +1,56 @@
+#include <stdio.h>
+
+#define DIGITS 60
+
+typedef char number[DIGITS];
+
+void add (char *a, char *b, char *c)
+{
+  char carry = 0;
+  for (int i = 0; i < DIGITS; i++)
+    {
+      c[i] = a[i] + b[i] + carry;
+      if (c[i] > 9)
+        {
+          carry = 1;
+          c[i] -= 10;
+        }
+      else
+        carry = 0;
+    }
+}
+
+void copy (char *a, char *b)
+{
+  for (int i = 0; i < DIGITS; i++)
+    b[i] = a[i];
+}
+
+void print (char *a)
+{
+  int i = DIGITS - 1;
+  while (i > 0 && a[i] == 0)
+    i--;
+  while (i >= 0)
+    {
+      printf ("%d", a[i]);
+      i--;
+    }
+}
+
+int main (void)
+{
+  number f0 = { 0 };
+  number f1 = { 1 };
+  for (int i = 0; i < 200; i++)
+    {
+      printf ("f[%d] = ", i);
+      print (f0);
+      printf ("\n");
+      number f2;
+      add (f0, f1, f2);
+      copy (f1, f0);
+      copy (f2, f1);
+    }
+  return 0;
+}
diff --git a/20201203/fibonacci-11.c b/20201203/fibonacci-11.c
new file mode 100644
index 0000000..f952267
--- /dev/null
+++ b/20201203/fibonacci-11.c
@@ -0,0 +1,56 @@
+#include <stdio.h>
+
+#define DIGITS 20000
+
+typedef char number[DIGITS];
+
+void add (char *a, char *b, char *c)
+{
+  char carry = 0;
+  for (int i = 0; i < DIGITS; i++)
+    {
+      c[i] = a[i] + b[i] + carry;
+      if (c[i] > 9)
+        {
+          carry = 1;
+          c[i] -= 10;
+        }
+      else
+        carry = 0;
+    }
+}
+
+void copy (char *a, char *b)
+{
+  for (int i = 0; i < DIGITS; i++)
+    b[i] = a[i];
+}
+
+void print (char *a)
+{
+  int i = DIGITS - 1;
+  while (i > 0 && a[i] == 0)
+    i--;
+  while (i >= 0)
+    {
+      printf ("%d", a[i]);
+      i--;
+    }
+}
+
+int main (void)
+{
+  number f0 = { 0 };
+  number f1 = { 1 };
+  for (int i = 0; i < 10000; i++)
+    {
+      printf ("f[%d] = ", i);
+      print (f0);
+      printf ("\n");
+      number f2;
+      add (f0, f1, f2);
+      copy (f1, f0);
+      copy (f2, f1);
+    }
+  return 0;
+}
diff --git a/20201203/fibonacci-2.c b/20201203/fibonacci-2.c
new file mode 100644
index 0000000..dc1673c
--- /dev/null
+++ b/20201203/fibonacci-2.c
@@ -0,0 +1,21 @@
+#include <stdio.h>
+
+void add (int *a, int *b, int *c)
+{
+  *c = *a + *b;
+}
+
+int main (void)
+{
+  int f0 = 0;
+  int f1 = 1;
+  for (int i = 0; i < 50; i++)
+    {
+      printf ("f[%d] = %d\n", i, f0);
+      int f2;
+      add (&f0, &f1, &f2);
+      f0 = f1;
+      f1 = f2;
+    }
+  return 0;
+}
diff --git a/20201203/fibonacci-3.c b/20201203/fibonacci-3.c
new file mode 100644
index 0000000..be44c77
--- /dev/null
+++ b/20201203/fibonacci-3.c
@@ -0,0 +1,23 @@
+#include <stdio.h>
+
+typedef int number;
+
+void add (number *a, number *b, number *c)
+{
+  *c = *a + *b;
+}
+
+int main (void)
+{
+  number f0 = 0;
+  number f1 = 1;
+  for (int i = 0; i < 50; i++)
+    {
+      printf ("f[%d] = %d\n", i, f0);
+      number f2;
+      add (&f0, &f1, &f2);
+      f0 = f1;
+      f1 = f2;
+    }
+  return 0;
+}
diff --git a/20201203/fibonacci-4.c b/20201203/fibonacci-4.c
new file mode 100644
index 0000000..0781697
--- /dev/null
+++ b/20201203/fibonacci-4.c
@@ -0,0 +1,31 @@
+#include <stdio.h>
+
+#define DIGITS 42
+
+typedef char number[DIGITS];
+
+void add (number *a, number *b, number *c)
+{
+  c[0] = a[0] + b[0];
+}
+
+void copy (number *a, number *b)
+{
+  for (int i = 0; i < DIGITS; i++)
+    b[i] = a[i];
+}
+
+int main (void)
+{
+  number f0 = { 0 };
+  number f1 = { 1 };
+  for (int i = 0; i < 50; i++)
+    {
+      printf ("f[%d] = %d\n", i, f0);
+      number f2;
+      add (&f0, &f1, &f2);
+      copy (f1, f0);
+      copy (f2, f1);
+    }
+  return 0;
+}
diff --git a/20201203/fibonacci-5.c b/20201203/fibonacci-5.c
new file mode 100644
index 0000000..00ff7b3
--- /dev/null
+++ b/20201203/fibonacci-5.c
@@ -0,0 +1,31 @@
+#include <stdio.h>
+
+#define DIGITS 42
+
+typedef char number[DIGITS];
+
+void add (char *a, char *b, char *c)
+{
+  c[0] = a[0] + b[0];
+}
+
+void copy (char *a, char *b)
+{
+  for (int i = 0; i < DIGITS; i++)
+    b[i] = a[i];
+}
+
+int main (void)
+{
+  number f0 = { 0 };
+  number f1 = { 1 };
+  for (int i = 0; i < 50; i++)
+    {
+      printf ("f[%d] = %d\n", i, f0);
+      number f2;
+      add (f0, f1, f2);
+      copy (f1, f0);
+      copy (f2, f1);
+    }
+  return 0;
+}
diff --git a/20201203/fibonacci-6.c b/20201203/fibonacci-6.c
new file mode 100644
index 0000000..f5aa3f8
--- /dev/null
+++ b/20201203/fibonacci-6.c
@@ -0,0 +1,45 @@
+#include <stdio.h>
+
+#define DIGITS 42
+
+typedef char number[DIGITS];
+
+void add (char *a, char *b, char *c)
+{
+  c[0] = a[0] + b[0];
+}
+
+void copy (char *a, char *b)
+{
+  for (int i = 0; i < DIGITS; i++)
+    b[i] = a[i];
+}
+
+void print (char *a)
+{
+  int i = DIGITS - 1;
+  while (i > 0 && a[i] == 0)
+    i--;
+  while (i >= 0)
+    {
+      printf ("%d", a[i]);
+      i--;
+    }
+}
+
+int main (void)
+{
+  number f0 = { 0 };
+  number f1 = { 1 };
+  for (int i = 0; i < 50; i++)
+    {
+      printf ("f[%d] = ", i);
+      print (f0);
+      printf ("\n");
+      number f2;
+      add (f0, f1, f2);
+      copy (f1, f0);
+      copy (f2, f1);
+    }
+  return 0;
+}
diff --git a/20201203/fibonacci-7.c b/20201203/fibonacci-7.c
new file mode 100644
index 0000000..05e8e9e
--- /dev/null
+++ b/20201203/fibonacci-7.c
@@ -0,0 +1,47 @@
+#include <stdio.h>
+
+#define DIGITS 42
+
+typedef char number[DIGITS];
+
+void add (char *a, char *b, char *c)
+{
+  c[0] = a[0] + b[0];
+  for (int i = 1; i < DIGITS; i++)
+    c[i] = 0;
+}
+
+void copy (char *a, char *b)
+{
+  for (int i = 0; i < DIGITS; i++)
+    b[i] = a[i];
+}
+
+void print (char *a)
+{
+  int i = DIGITS - 1;
+  while (i > 0 && a[i] == 0)
+    i--;
+  while (i >= 0)
+    {
+      printf ("%d", a[i]);
+      i--;
+    }
+}
+
+int main (void)
+{
+  number f0 = { 0 };
+  number f1 = { 1 };
+  for (int i = 0; i < 50; i++)
+    {
+      printf ("f[%d] = ", i);
+      print (f0);
+      printf ("\n");
+      number f2;
+      add (f0, f1, f2);
+      copy (f1, f0);
+      copy (f2, f1);
+    }
+  return 0;
+}
diff --git a/20201203/fibonacci-8.c b/20201203/fibonacci-8.c
new file mode 100644
index 0000000..e76226b
--- /dev/null
+++ b/20201203/fibonacci-8.c
@@ -0,0 +1,71 @@
+#include <stdio.h>
+
+#define DIGITS 42
+
+typedef char number[DIGITS];
+
+void add (char *a, char *b, char *c)
+{
+  char carry;
+  c[0] = a[0] + b[0];
+  if (c[0] > 9)
+    {
+      carry = 1;
+      c[0] -= 10;
+    }
+  else
+    carry = 0;
+  c[1] = a[1] + b[1] + carry;
+  if (c[0] > 9)
+    {
+      carry = 1;
+      c[1] -= 10;
+    }
+  else
+    carry = 0;
+  c[2] = a[2] + b[2] + carry;
+  if (c[2] > 9)
+    {
+      carry = 1;
+      c[2] -= 10;
+    }
+  else
+    carry = 0;
+  for (int i = 3; i < DIGITS; i++)
+    c[i] = 0;
+}
+
+void copy (char *a, char *b)
+{
+  for (int i = 0; i < DIGITS; i++)
+    b[i] = a[i];
+}
+
+void print (char *a)
+{
+  int i = DIGITS - 1;
+  while (i > 0 && a[i] == 0)
+    i--;
+  while (i >= 0)
+    {
+      printf ("%d", a[i]);
+      i--;
+    }
+}
+
+int main (void)
+{
+  number f0 = { 0 };
+  number f1 = { 1 };
+  for (int i = 0; i < 50; i++)
+    {
+      printf ("f[%d] = ", i);
+      print (f0);
+      printf ("\n");
+      number f2;
+      add (f0, f1, f2);
+      copy (f1, f0);
+      copy (f2, f1);
+    }
+  return 0;
+}
diff --git a/20201203/fibonacci-9.c b/20201203/fibonacci-9.c
new file mode 100644
index 0000000..b73982f
--- /dev/null
+++ b/20201203/fibonacci-9.c
@@ -0,0 +1,56 @@
+#include <stdio.h>
+
+#define DIGITS 42
+
+typedef char number[DIGITS];
+
+void add (char *a, char *b, char *c)
+{
+  char carry = 0;
+  for (int i = 0; i < DIGITS; i++)
+    {
+      c[i] = a[i] + b[i] + carry;
+      if (c[i] > 9)
+        {
+          carry = 1;
+          c[i] -= 10;
+        }
+      else
+        carry = 0;
+    }
+}
+
+void copy (char *a, char *b)
+{
+  for (int i = 0; i < DIGITS; i++)
+    b[i] = a[i];
+}
+
+void print (char *a)
+{
+  int i = DIGITS - 1;
+  while (i > 0 && a[i] == 0)
+    i--;
+  while (i >= 0)
+    {
+      printf ("%d", a[i]);
+      i--;
+    }
+}
+
+int main (void)
+{
+  number f0 = { 0 };
+  number f1 = { 1 };
+  for (int i = 0; i < 50; i++)
+    {
+      printf ("f[%d] = ", i);
+      print (f0);
+      printf ("\n");
+      number f2;
+      add (f0, f1, f2);
+      copy (f1, f0);
+      copy (f2, f1);
+    }
+  return 0;
+}
diff --git a/20201203/integers-1.c b/20201203/integers-1.c
new file mode 100644
index 0000000..60a31e3
--- /dev/null
+++ b/20201203/integers-1.c
@@ -0,0 +1,9 @@
+#include <stdio.h>
+
+int main (void)
+{
+  int a = 42;
+  int b = 137;
+  printf ("%d\n", a + b);
+  return 0;
+}
diff --git a/20201203/integers-2.c b/20201203/integers-2.c
new file mode 100644
index 0000000..c90e017
--- /dev/null
+++ b/20201203/integers-2.c
@@ -0,0 +1,9 @@
+#include <stdio.h>
+
+int main (void)
+{
+  int a = 1500000000;
+  int b = 1500000000;
+  printf ("%d\n", a + b);
+  return 0;
+}
diff --git a/20201203/integers-2.s b/20201203/integers-2.s
new file mode 100644
index 0000000..28aa51f
--- /dev/null
+++ b/20201203/integers-2.s
@@ -0,0 +1,26 @@
+	.file	"integers-2.c"
+	.text
+	.section	.rodata.str1.1,"aMS",@progbits,1
+.LC0:
+	.string	"%d\n"
+	.text
+	.globl	main
+	.type	main, @function
+main:
+.LFB11:
+	.cfi_startproc
+	subq	$8, %rsp
+	.cfi_def_cfa_offset 16
+	movl	$-1294967296, %esi
+	leaq	.LC0(%rip), %rdi
+	movl	$0, %eax
+	call	printf@PLT
+	movl	$0, %eax
+	addq	$8, %rsp
+	.cfi_def_cfa_offset 8
+	ret
+	.cfi_endproc
+.LFE11:
+	.size	main, .-main
+	.ident	"GCC: (Debian 8.3.0-6) 8.3.0"
+	.section	.note.GNU-stack,"",@progbits
diff --git a/20201203/setup-loop-1.c b/20201203/setup-loop-1.c
new file mode 100644
index 0000000..6058936
--- /dev/null
+++ b/20201203/setup-loop-1.c
@@ -0,0 +1,16 @@
+#include <stdio.h>
+
+void setup (void)
+{
+  printf ("Arduino wird initialisiert.\n");
+}
+
+void loop (void)
+{
+  printf ("Arduino läuft.\n");
+}
+
+int main (void)
+{
+  return 0;
+}
diff --git a/20201203/setup-loop-2.c b/20201203/setup-loop-2.c
new file mode 100644
index 0000000..f3689d0
--- /dev/null
+++ b/20201203/setup-loop-2.c
@@ -0,0 +1,19 @@
+#include <stdio.h>
+
+void setup (void)
+{
+  printf ("Arduino wird initialisiert.\n");
+}
+
+void loop (void)
+{
+  printf ("Arduino läuft.\n");
+}
+
+int main (void)
+{
+  setup ();
+  while (1)
+    loop ();
+  return 0;
+}
diff --git a/20201203/string-operations-1.c b/20201203/string-operations-1.c
new file mode 100644
index 0000000..9216307
--- /dev/null
+++ b/20201203/string-operations-1.c
@@ -0,0 +1,21 @@
+#include <stdio.h>
+#include <string.h>
+
+int main (void)
+{
+  char hello[] = "Hello, world!\n";
+
+  printf ("%s\n", hello);
+  printf ("%zd\n", strlen (hello));
+
+/*
+  printf ("%s\n", hello + 7);
+  printf ("%zd\n", strlen (hello + 7));
+
+  hello[5] = 0;
+  printf ("%s\n", hello);
+  printf ("%zd\n", strlen (hello));
+*/
+
+  return 0;
+}
diff --git a/20201203/string-operations-10.c b/20201203/string-operations-10.c
new file mode 100644
index 0000000..ff4e437
--- /dev/null
+++ b/20201203/string-operations-10.c
@@ -0,0 +1,31 @@
+#include <stdio.h>
+#include <string.h>
+
+int main (void)
+{
+  char *zacharias = "Zacharias";
+  char *anton = "Anton";
+
+  printf ("%d\n", strcmp (anton, zacharias));
+  printf ("%d\n", strcmp (zacharias, anton));
+  printf ("%d\n", strcmp (anton, anton));
+
+  char anton1[] = "Anton";
+  char anton2[] = "Anton";
+
+  if (anton1 < anton2)   /* vergleicht die Nummern der Speicherzellen --> meistens nicht sinnvoll */
+    printf ("%d\n", -1);
+  else if (anton1 > anton2)
+    printf ("%d\n", 1);
+  else
+    printf ("%d\n", 0);
+  printf ("%d\n", strcmp (anton1, anton2));
+
+/*
+  char buffer[100] = "Huber ";
+  strcat (buffer, anton);
+  printf ("%s\n", buffer);
+*/
+
+  return 0;
+}
diff --git a/20201203/string-operations-11.c b/20201203/string-operations-11.c
new file mode 100644
index 0000000..7966ffe
--- /dev/null
+++ b/20201203/string-operations-11.c
@@ -0,0 +1,20 @@
+#include <stdio.h>
+#include <string.h>
+
+int main (void)
+{
+  char *anton = "Anton";
+  char *zacharias = "Zacharias";
+
+/*
+  printf ("%d\n", strcmp (anton, zacharias));
+  printf ("%d\n", strcmp (zacharias, anton));
+  printf ("%d\n", strcmp (anton, anton));
+*/
+
+  char buffer[100] = "Huber ";
+  strcat (buffer, anton);
+  printf ("%s\n", buffer);
+
+  return 0;
+}
diff --git a/20201203/string-operations-12.c b/20201203/string-operations-12.c
new file mode 100644
index 0000000..c95d341
--- /dev/null
+++ b/20201203/string-operations-12.c
@@ -0,0 +1,20 @@
+#include <stdio.h>
+#include <string.h>
+
+int main (void)
+{
+  char *anton = "Anton";
+  char *zacharias = "Zacharias";
+
+/*
+  printf ("%d\n", strcmp (anton, zacharias));
+  printf ("%d\n", strcmp (zacharias, anton));
+  printf ("%d\n", strcmp (anton, anton));
+*/
+
+  char buffer[6] = "Huber ";  /* Kein Platz für das Null-Symbol --> String ohne Null-Symbol! */
+  strcat (buffer, anton);     /* Pufferüberlauf */
+  printf ("%s\n", buffer);
+
+  return 0;
+}
diff --git a/20201203/string-operations-13.c b/20201203/string-operations-13.c
new file mode 100644
index 0000000..0d14e91
--- /dev/null
+++ b/20201203/string-operations-13.c
@@ -0,0 +1,20 @@
+#include <stdio.h>
+#include <string.h>
+
+int main (void)
+{
+  char *anton = "Anton";
+  char *zacharias = "Zacharias";
+
+/*
+  printf ("%d\n", strcmp (anton, zacharias));
+  printf ("%d\n", strcmp (zacharias, anton));
+  printf ("%d\n", strcmp (anton, anton));
+*/
+
+  char buffer[] = "Huber ";
+  strcat (buffer, anton);     /* Pufferüberlauf */
+  printf ("%s\n", buffer);
+
+  return 0;
+}
diff --git a/20201203/string-operations-14.c b/20201203/string-operations-14.c
new file mode 100644
index 0000000..e867f6a
--- /dev/null
+++ b/20201203/string-operations-14.c
@@ -0,0 +1,21 @@
+#include <stdio.h>
+#include <string.h>
+
+int main (void)
+{
+  char *anton = "Anton";
+  char *zacharias = "Zacharias";
+
+/*
+  printf ("%d\n", strcmp (anton, zacharias));
+  printf ("%d\n", strcmp (zacharias, anton));
+  printf ("%d\n", strcmp (anton, anton));
+*/
+
+  char buffer[] = "Huber ";
+  for (int i = 0; i < 5; i++)
+    strcat (buffer, anton);     /* Pufferüberlauf */
+  printf ("%s\n", buffer);
+
+  return 0;
+}
diff --git a/20201203/string-operations-15.c b/20201203/string-operations-15.c
new file mode 100644
index 0000000..a7c37b1
--- /dev/null
+++ b/20201203/string-operations-15.c
@@ -0,0 +1,21 @@
+#include <stdio.h>
+#include <string.h>
+
+int main (void)
+{
+  char *anton = "Anton";
+  char *zacharias = "Zacharias";
+
+/*
+  printf ("%d\n", strcmp (anton, zacharias));
+  printf ("%d\n", strcmp (zacharias, anton));
+  printf ("%d\n", strcmp (anton, anton));
+*/
+
+  char buffer[100] = "Huber ";
+  for (int i = 0; i < 5; i++)
+    strncat (buffer, anton, 100);  /* Ebenfalls Puffer-überlauf, da sich die 100 auf die */
+  printf ("%s\n", buffer);         /* maximale Länge von "anton" bezieht.                */
+
+  return 0;
+}
diff --git a/20201203/string-operations-16.c b/20201203/string-operations-16.c
new file mode 100644
index 0000000..8101ccf
--- /dev/null
+++ b/20201203/string-operations-16.c
@@ -0,0 +1,17 @@
+#include <stdio.h>
+#include <string.h>
+
+int main (void)
+{
+  char buffer[100] = "";
+  sprintf (buffer, "Die Antwort lautet: %d", 42);
+  printf ("%s\n", buffer);
+
+/*
+  char *answer = strstr (buffer, "Antwort");
+  printf ("%s\n", answer);
+  printf ("found at: %zd\n", answer - buffer);
+*/
+
+  return 0;
+}
diff --git a/20201203/string-operations-17.c b/20201203/string-operations-17.c
new file mode 100644
index 0000000..efaddc2
--- /dev/null
+++ b/20201203/string-operations-17.c
@@ -0,0 +1,17 @@
+#include <stdio.h>
+#include <string.h>
+
+int main (void)
+{
+  char buffer[10] = "";
+  sprintf (buffer, "Die Antwort lautet: %d", 42);
+  printf ("%s\n", buffer);
+
+/*
+  char *answer = strstr (buffer, "Antwort");
+  printf ("%s\n", answer);
+  printf ("found at: %zd\n", answer - buffer);
+*/
+
+  return 0;
+}
diff --git a/20201203/string-operations-18.c b/20201203/string-operations-18.c
new file mode 100644
index 0000000..5ccb108
--- /dev/null
+++ b/20201203/string-operations-18.c
@@ -0,0 +1,17 @@
+#include <stdio.h>
+#include <string.h>
+
+int main (void)
+{
+  char buffer[10] = "";
+  snprintf (buffer, 10, "Die Antwort lautet: %d", 42);
+  printf ("%s\n", buffer);
+
+/*
+  char *answer = strstr (buffer, "Antwort");
+  printf ("%s\n", answer);
+  printf ("found at: %zd\n", answer - buffer);
+*/
+
+  return 0;
+}
diff --git a/20201203/string-operations-19.c b/20201203/string-operations-19.c
new file mode 100644
index 0000000..e1c1e84
--- /dev/null
+++ b/20201203/string-operations-19.c
@@ -0,0 +1,15 @@
+#include <stdio.h>
+#include <string.h>
+
+int main (void)
+{
+  char buffer[100] = "";
+  snprintf (buffer, 100, "Die Antwort lautet: %d", 42);
+  printf ("%s\n", buffer);
+
+  char *answer = strstr (buffer, "Antwort");
+  printf ("%s\n", answer);
+  printf ("found at: %zd\n", answer - buffer);
+
+  return 0;
+}
diff --git a/20201203/string-operations-2.c b/20201203/string-operations-2.c
new file mode 100644
index 0000000..dbeea54
--- /dev/null
+++ b/20201203/string-operations-2.c
@@ -0,0 +1,23 @@
+#include <stdio.h>
+#include <string.h>
+
+int main (void)
+{
+  char hello[] = "Hello, world!\n";
+
+/*
+  printf ("%s\n", hello);
+  printf ("%zd\n", strlen (hello));
+*/
+
+  printf ("%s\n", hello + 7);
+  printf ("%zd\n", strlen (hello + 7));
+
+/*
+  hello[5] = 0;
+  printf ("%s\n", hello);
+  printf ("%zd\n", strlen (hello));
+*/
+
+  return 0;
+}
diff --git a/20201203/string-operations-3.c b/20201203/string-operations-3.c
new file mode 100644
index 0000000..2f1b534
--- /dev/null
+++ b/20201203/string-operations-3.c
@@ -0,0 +1,23 @@
+#include <stdio.h>
+#include <string.h>
+
+int main (void)
+{
+  char hello[] = "Hello, world!\n";
+
+/*
+  printf ("%s\n", hello);
+  printf ("%zd\n", strlen (hello));
+*/
+
+  printf ("%s\n", hello + 16);
+  printf ("%zd\n", strlen (hello + 16));
+
+/*
+  hello[5] = 0;
+  printf ("%s\n", hello);
+  printf ("%zd\n", strlen (hello));
+*/
+
+  return 0;
+}
diff --git a/20201203/string-operations-4.c b/20201203/string-operations-4.c
new file mode 100644
index 0000000..dee5c1d
--- /dev/null
+++ b/20201203/string-operations-4.c
@@ -0,0 +1,23 @@
+#include <stdio.h>
+#include <string.h>
+
+int main (void)
+{
+  char hello[] = "Hello, world!\n";
+
+/*
+  printf ("%s\n", hello);
+  printf ("%zd\n", strlen (hello));
+*/
+
+  printf ("%s\n", hello + 16000000);
+  printf ("%zd\n", strlen (hello + 16000000));
+
+/*
+  hello[5] = 0;
+  printf ("%s\n", hello);
+  printf ("%zd\n", strlen (hello));
+*/
+
+  return 0;
+}
diff --git a/20201203/string-operations-5.c b/20201203/string-operations-5.c
new file mode 100644
index 0000000..2d15ca2
--- /dev/null
+++ b/20201203/string-operations-5.c
@@ -0,0 +1,21 @@
+#include <stdio.h>
+#include <string.h>
+
+int main (void)
+{
+  char hello[] = "Hello, world!\n";
+
+/*
+  printf ("%s\n", hello);
+  printf ("%zd\n", strlen (hello));
+
+  printf ("%s\n", hello + 16000000);
+  printf ("%zd\n", strlen (hello + 16000000));
+*/
+
+  hello[5] = 0;
+  printf ("%s\n", hello);
+  printf ("%zd\n", strlen (hello));
+
+  return 0;
+}
diff --git a/20201203/string-operations-6.c b/20201203/string-operations-6.c
new file mode 100644
index 0000000..95e8268
--- /dev/null
+++ b/20201203/string-operations-6.c
@@ -0,0 +1,20 @@
+#include <stdio.h>
+#include <string.h>
+
+int main (void)
+{
+  char *anton = "Anton";
+  char *zacharias = "Zacharias";
+
+  printf ("%d\n", strcmp (anton, zacharias));
+  printf ("%d\n", strcmp (zacharias, anton));
+  printf ("%d\n", strcmp (anton, anton));
+
+/*
+  char buffer[100] = "Huber ";
+  strcat (buffer, anton);
+  printf ("%s\n", buffer);
+*/
+
+  return 0;
+}
diff --git a/20201203/string-operations-7.c b/20201203/string-operations-7.c
new file mode 100644
index 0000000..f668bc6
--- /dev/null
+++ b/20201203/string-operations-7.c
@@ -0,0 +1,20 @@
+#include <stdio.h>
+#include <string.h>
+
+int main (void)
+{
+  char *anton = "anton";
+  char *zacharias = "Zacharias";
+
+  printf ("%d\n", strcmp (anton, zacharias));
+  printf ("%d\n", strcmp (zacharias, anton));
+  printf ("%d\n", strcmp (anton, anton));
+
+/*
+  char buffer[100] = "Huber ";
+  strcat (buffer, anton);
+  printf ("%s\n", buffer);
+*/
+
+  return 0;
+}
diff --git a/20201203/string-operations-8.c b/20201203/string-operations-8.c
new file mode 100644
index 0000000..f4d4f74
--- /dev/null
+++ b/20201203/string-operations-8.c
@@ -0,0 +1,27 @@
+#include <stdio.h>
+#include <string.h>
+
+int main (void)
+{
+  char *anton = "Anton";
+  char *zacharias = "Zacharias";
+
+  printf ("%d\n", strcmp (anton, zacharias));
+  printf ("%d\n", strcmp (zacharias, anton));
+  printf ("%d\n", strcmp (anton, anton));
+
+  if (anton < zacharias)   /* vergleicht die Nummern der Speicherzellen --> meistens nicht sinnvoll */
+    printf ("%d\n", -1);
+  else if (anton > zacharias)
+    printf ("%d\n", 1);
+  else
+    printf ("%d\n", 0);
+
+/*
+  char buffer[100] = "Huber ";
+  strcat (buffer, anton);
+  printf ("%s\n", buffer);
+*/
+
+  return 0;
+}
diff --git a/20201203/string-operations-8.s b/20201203/string-operations-8.s
new file mode 100644
index 0000000..e5e78f9
--- /dev/null
+++ b/20201203/string-operations-8.s
@@ -0,0 +1,65 @@
+	.file	"string-operations-8.c"
+	.text
+	.section	.rodata.str1.1,"aMS",@progbits,1
+.LC0:
+	.string	"%d\n"
+.LC1:
+	.string	"Anton"
+.LC2:
+	.string	"Zacharias"
+	.text
+	.globl	main
+	.type	main, @function
+main:
+.LFB11:
+	.cfi_startproc
+	subq	$8, %rsp
+	.cfi_def_cfa_offset 16
+	movl	$-1, %esi
+	leaq	.LC0(%rip), %rdi
+	movl	$0, %eax
+	call	printf@PLT
+	movl	$1, %esi
+	leaq	.LC0(%rip), %rdi
+	movl	$0, %eax
+	call	printf@PLT
+	movl	$0, %esi
+	leaq	.LC0(%rip), %rdi
+	movl	$0, %eax
+	call	printf@PLT
+	leaq	.LC1(%rip), %rdx
+	leaq	.LC2(%rip), %rax
+	cmpq	%rax, %rdx
+	jb	.L6
+	leaq	.LC1(%rip), %rdx
+	leaq	.LC2(%rip), %rax
+	cmpq	%rax, %rdx
+	jbe	.L4
+	movl	$1, %esi
+	leaq	.LC0(%rip), %rdi
+	movl	$0, %eax
+	call	printf@PLT
+.L3:
+	movl	$0, %eax
+	addq	$8, %rsp
+	.cfi_remember_state
+	.cfi_def_cfa_offset 8
+	ret
+.L6:
+	.cfi_restore_state
+	movl	$-1, %esi
+	leaq	.LC0(%rip), %rdi
+	movl	$0, %eax
+	call	printf@PLT
+	jmp	.L3
+.L4:
+	movl	$0, %esi
+	leaq	.LC0(%rip), %rdi
+	movl	$0, %eax
+	call	printf@PLT
+	jmp	.L3
+	.cfi_endproc
+.LFE11:
+	.size	main, .-main
+	.ident	"GCC: (Debian 8.3.0-6) 8.3.0"
+	.section	.note.GNU-stack,"",@progbits
diff --git a/20201203/string-operations-9.c b/20201203/string-operations-9.c
new file mode 100644
index 0000000..74802a1
--- /dev/null
+++ b/20201203/string-operations-9.c
@@ -0,0 +1,27 @@
+#include <stdio.h>
+#include <string.h>
+
+int main (void)
+{
+  char *zacharias = "Zacharias";
+  char *anton = "Anton";
+
+  printf ("%d\n", strcmp (anton, zacharias));
+  printf ("%d\n", strcmp (zacharias, anton));
+  printf ("%d\n", strcmp (anton, anton));
+
+  if (anton < zacharias)   /* vergleicht die Nummern der Speicherzellen --> meistens nicht sinnvoll */
+    printf ("%d\n", -1);
+  else if (anton > zacharias)
+    printf ("%d\n", 1);
+  else
+    printf ("%d\n", 0);
+
+/*
+  char buffer[100] = "Huber ";
+  strcat (buffer, anton);
+  printf ("%s\n", buffer);
+*/
+
+  return 0;
+}
diff --git a/20201203/string-operations-9.s b/20201203/string-operations-9.s
new file mode 100644
index 0000000..09a5ead
--- /dev/null
+++ b/20201203/string-operations-9.s
@@ -0,0 +1,65 @@
+	.file	"string-operations-9.c"
+	.text
+	.section	.rodata.str1.1,"aMS",@progbits,1
+.LC0:
+	.string	"%d\n"
+.LC1:
+	.string	"Anton"
+.LC2:
+	.string	"Zacharias"
+	.text
+	.globl	main
+	.type	main, @function
+main:
+.LFB11:
+	.cfi_startproc
+	subq	$8, %rsp
+	.cfi_def_cfa_offset 16
+	movl	$-1, %esi
+	leaq	.LC0(%rip), %rdi
+	movl	$0, %eax
+	call	printf@PLT
+	movl	$1, %esi
+	leaq	.LC0(%rip), %rdi
+	movl	$0, %eax
+	call	printf@PLT
+	movl	$0, %esi
+	leaq	.LC0(%rip), %rdi
+	movl	$0, %eax
+	call	printf@PLT
+	leaq	.LC1(%rip), %rdx
+	leaq	.LC2(%rip), %rax
+	cmpq	%rax, %rdx
+	jb	.L6
+	leaq	.LC1(%rip), %rdx
+	leaq	.LC2(%rip), %rax
+	cmpq	%rax, %rdx
+	jbe	.L4
+	movl	$1, %esi
+	leaq	.LC0(%rip), %rdi
+	movl	$0, %eax
+	call	printf@PLT
+.L3:
+	movl	$0, %eax
+	addq	$8, %rsp
+	.cfi_remember_state
+	.cfi_def_cfa_offset 8
+	ret
+.L6:
+	.cfi_restore_state
+	movl	$-1, %esi
+	leaq	.LC0(%rip), %rdi
+	movl	$0, %eax
+	call	printf@PLT
+	jmp	.L3
+.L4:
+	movl	$0, %esi
+	leaq	.LC0(%rip), %rdi
+	movl	$0, %eax
+	call	printf@PLT
+	jmp	.L3
+	.cfi_endproc
+.LFE11:
+	.size	main, .-main
+	.ident	"GCC: (Debian 8.3.0-6) 8.3.0"
+	.section	.note.GNU-stack,"",@progbits
-- 
GitLab