From 08fd74a723d544c352deb887cc2f777574945412 Mon Sep 17 00:00:00 2001 From: Raduta Alexandru Date: Sat, 26 Oct 2024 11:35:03 +0300 Subject: [PATCH 1/2] Added a line of text at the start of the document --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 2ef3ea5..9d71fcb 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ # Markdown Workshop +some text at the beggining + This is a practical workshop about the syntax and the use of the [Markdown format](https://www.markdownguide.org/basic-syntax/). In particular, we will focus on the [GitHub Flavored Markdown](https://docs.github.com/en/get-started/writing-on-github/getting-started-with-writing-and-formatting-on-github/basic-writing-and-formatting-syntax), used by GitHub. See the full specification of the GitHub Flavored Markdown [here](https://github.github.com/gfm/). From d6a12cf0a7b4386f5ecf48461b68eea5439a0645 Mon Sep 17 00:00:00 2001 From: Raduta Alexandru Date: Sat, 26 Oct 2024 12:38:28 +0300 Subject: [PATCH 2/2] Created the Markdown file for C and C++ Hello World! programs --- helloworld.md | 62 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) create mode 100644 helloworld.md diff --git a/helloworld.md b/helloworld.md new file mode 100644 index 0000000..827d3f8 --- /dev/null +++ b/helloworld.md @@ -0,0 +1,62 @@ +# Helloworld Programs + +![hello-world](./helloworld.png) + +We list below Helloworld programs for different programming languages, i.e. programs that print "Hello, World!". The specified compiler or interpreter is required for each programming languages. + +The table below summarizes the programs: + +| Language | Language (Spec) Site | Section | Build / Run Toolchain | Debian / Ubuntu Packages | +| :--------| :--------------------| :-------| :---------------------| :------------------------| +| C | [The standard - C]() | [C]() | GCC | `build-essential` | +| C++ | [The standard - C++]() | [C++]()| GCC / G++ | `build-essential, g++` | + +## C + +```C + +#include + +int main(void) { + puts("Hello, World!"); + return 0; +} + +``` + +Build with: + + ```Bash + gcc -Wall -o helloworld helloworld.c + ``` + +Run with: + + ```Bash + ./helloworld + ``` + +## C++ + +```C++ + +#include + +int main() { + std::cout << "Hello, World!" << std::endl; + return 0; +} + +``` + +Build with: + +```Bash +g++ -Wall -o helloworld helloworld.cpp +``` + +Run with: + +```Bash +./helloworld +```