about summary refs log tree commit diff stats
path: root/org/c/ex_01.org
diff options
context:
space:
mode:
authorelioat <hi@eli.li>2022-11-26 19:56:33 -0500
committerelioat <hi@eli.li>2022-11-26 19:56:33 -0500
commitd9bf844148e0ca641c0894215c6afa0604229dc8 (patch)
treee7631da5da32aa9e9b26ed50efc64a6042a4f427 /org/c/ex_01.org
parent885e0d2a059bc14549bbec6f307e210cc3cb00a3 (diff)
downloadhard-way-d9bf844148e0ca641c0894215c6afa0604229dc8.tar.gz
*
Diffstat (limited to 'org/c/ex_01.org')
-rw-r--r--org/c/ex_01.org20
1 files changed, 20 insertions, 0 deletions
diff --git a/org/c/ex_01.org b/org/c/ex_01.org
new file mode 100644
index 0000000..d479a84
--- /dev/null
+++ b/org/c/ex_01.org
@@ -0,0 +1,20 @@
+* Exercise 1.
+
+
+#+BEGIN_SRC C
+  #include <stdio.h>
+
+  int main(int argc, char *argv[])
+    {
+      int distance = 100;
+
+      printf("you are %d miles away.\n", distance);
+
+      return 0;
+    }
+#+END_SRC
+
+#+RESULTS:
+: you are 100 miles away.
+
+Big notable bits from this are the ~#include~.