From 442a49ad5a48d417345959b903ae6a6d32d55759 Mon Sep 17 00:00:00 2001 From: Haidong Ji Date: Fri, 15 Apr 2022 15:51:30 -0500 Subject: Great C programming fun Excellent fundamentals and displine training, many tools and techniques exercises: gdb, emacs, valgrind, git --- 04_compile/README | 16 ++++++++++++++++ 04_compile/grade.txt | 6 ++++++ 04_compile/hello.c | 7 +++++++ 3 files changed, 29 insertions(+) create mode 100644 04_compile/README create mode 100644 04_compile/grade.txt create mode 100644 04_compile/hello.c (limited to '04_compile') diff --git a/04_compile/README b/04_compile/README new file mode 100644 index 0000000..dd090e6 --- /dev/null +++ b/04_compile/README @@ -0,0 +1,16 @@ +For this assignment, you will be practicing writing, compiling, and +running code. You should write a C file, called hello.c, with a main +function that uses the printf function to print the message + +Hello World + +[be sure to include a newline!] + +Your program should return EXIT_SUCCESS to indicate that it was successful +(the return value of main indicates success [0] or failure [anything else]). + +Don't forget to include stdio.h (for printf) and stdlib.h (for +EXIT_SUCCESS). + +When you are done, compile your code and run it. +The submit it for grading. diff --git a/04_compile/grade.txt b/04_compile/grade.txt new file mode 100644 index 0000000..ebec7bb --- /dev/null +++ b/04_compile/grade.txt @@ -0,0 +1,6 @@ +Grading at Sat 27 Nov 2021 02:23:56 AM UTC +Compiling your code +Checking if your program prints "Hello World" +Your file matched the expected output + +Overall Grade: PASSED diff --git a/04_compile/hello.c b/04_compile/hello.c new file mode 100644 index 0000000..30c032e --- /dev/null +++ b/04_compile/hello.c @@ -0,0 +1,7 @@ +#include +#include + +int main() { + printf("Hello World\n"); + return EXIT_SUCCESS; +} -- cgit v1.2.3