We decided to keep the coding standard simple so you can worry less about the standard and more about learning. The coding standard has the following requirements:
C Coding Standard
-
All code must be written in C.
-
You must use ClangFormat to format your code with the following options:
- Open up VSCode and type in
Ctrl + ,
- In the search bar, type in
clang
-
Under the section that says C_Cpp: Clang_format_style, enter in
{ BasedOnStyle: LLVM, UseTab: Never, IndentWidth: 4, TabWidth: 4, ColumnLimit: 100, InsertBraces: true }
- Then type in
Format on save
in the search bar and check the box under Format on Save
- Open up VSCode and type in
-
For every function you write, have a block comment before it explaining what the function does.
Markdown Coding Guidelines
- Headers:
- Use # for headers and follow a hierarchical structure (# for top-level, ## for second-level, etc.).
- Lists:
- Use
-
or*
for unordered lists. - Use
1.
for ordered lists.
- Use
- Formatting:
- Bold: Use
**bold text**
- Italic: Use
*italicized text*
- Bold: Use
- Links:
- Inline links should be formatted as
[link text](URL)
.
- Inline links should be formatted as
- Code Blocks:
- Indent code blocks with four spaces or use triple backticks ``` for fenced code blocks.
- Escape Characters:
- Use backslash
\
to escape Markdown characters if needed.
- Use backslash
- Comments:
- Use HTML comments
<!-- comment -->
sparingly for notes or explanations within the Markdown.
- Use HTML comments