{"id":19449394,"url":"https://github.com/aavache/cpp-tutorial","last_synced_at":"2025-07-19T10:33:24.658Z","repository":{"id":189471957,"uuid":"680728910","full_name":"Aavache/cpp-tutorial","owner":"Aavache","description":"Get started with C++ with this tutorial repository. It contains plenty of intuitive examples.","archived":false,"fork":false,"pushed_at":"2023-08-20T08:01:15.000Z","size":74,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-25T09:18:55.981Z","etag":null,"topics":["cmake","cpp","cpp-programming","getting-started","patterns","pointers","programming","tutorial"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Aavache.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2023-08-20T07:47:37.000Z","updated_at":"2023-08-20T08:01:56.000Z","dependencies_parsed_at":"2023-08-20T09:42:39.377Z","dependency_job_id":"2645c2d2-18fe-44d8-98c8-076974f96f3a","html_url":"https://github.com/Aavache/cpp-tutorial","commit_stats":null,"previous_names":["aavache/cpp-tutorial"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Aavache/cpp-tutorial","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Aavache%2Fcpp-tutorial","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Aavache%2Fcpp-tutorial/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Aavache%2Fcpp-tutorial/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Aavache%2Fcpp-tutorial/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Aavache","download_url":"https://codeload.github.com/Aavache/cpp-tutorial/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Aavache%2Fcpp-tutorial/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265916205,"owners_count":23848708,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cmake","cpp","cpp-programming","getting-started","patterns","pointers","programming","tutorial"],"created_at":"2024-11-10T16:32:22.790Z","updated_at":"2025-07-19T10:33:24.635Z","avatar_url":"https://github.com/Aavache.png","language":"C++","readme":"# C++ Tutorial   💻 💾 \nLearn C++ in one evening with this brief yet straight to the point tutorial.\n\n\u003cp align=\"center\"\u003e\n  \u003cimg width=\"200\" height=\"200\" src=\"https://upload.wikimedia.org/wikipedia/commons/1/18/ISO_C%2B%2B_Logo.svg\"\u003e\n\u003c/p\u003e\n\n# About this repository\n\nWe divided the repository is sections starting from `00_hello_world`. Each of the sections will teach you gradually the syntax of C++, from zero to (almost) hero. Drop a ⭐️ if you found it helpful!.\n\n# Compile and run the examples\n\nChoose and install your favorite C++ compiler (I will use g++). If you wish to learn how to compile your code visit this links if you are a [Window](https://stackoverflow.com/questions/11365850/run-c-in-command-prompt-windows), [Linux](https://www.cyberciti.biz/faq/howto-compile-and-run-c-cplusplus-code-in-linux/) or [MacOS](https://siytek.com/how-to-compile-cpp-on-a-mac/) user. Then compile and execute the output binaries, here's what I do to run the first `hello world` example:\n\n```sh\ncd 01-hello-world\ng++ 00_hello_world.cpp\n```\n\nFinally, we can execute the binary as:\n\n```sh\n./a.out\n```\n\n# How compilation works\n\nAccording to this helpful [resource](https://www.mycplus.com/tutorials/cplusplus-programming-tutorials/what-are-the-best-c-compilers-to-use-in-2023/#google_vignette), the compiler goes through the following 5 steps:\n\n1. **Pre-processing**: First, the pre-processor reads the source code and performs macro expansions, inclusion of header files, and other operations as specified by pre-processor directives (#include, #define, #ifndef, etc.).\n2. **Compilation**: Second step performs the actual translation of the source code into object code. The object code is a machine-readable representation of the source code, but it is not yet executable.\n3. **Assembly**: The compiler then passes the object code to an assembler, which converts the object code into assembly code.\n4. **Linking**: The linker then combines assembly code with any library functions that are required by the program and resolves any references to external symbols/libraries. The linker produces an executable file to run on the target platform.\n5. **Execution**: Finally, the compiler produces and executable file that runs on the computer system.\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faavache%2Fcpp-tutorial","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faavache%2Fcpp-tutorial","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faavache%2Fcpp-tutorial/lists"}