Coding Convention
Every programming language has a different convention (or style) and guidelines to write code These conventions cover various aspects of code formatting, naming conventions, indentation, commenting practices, and more. They aim to ensure consistency and readability across codebases, making it easier for developers to understand and maintain the code.
In SRON, the coding convention typically includes the following guidelines:
1. Datatypes: They should be written in Capitalized which means starting with a capital letter and using capital letters for the beginning of each word in the name, e.g., String, Int, Double, Char, Bool and List.
2. Indentation: It is typically done using spaces (usually four spaces per indentation level).
3. Variables: It should be written in lower case separated by underscore.
4. Arguments: They should start with two underscores, followed by alphabets in lower case.
5. Method names: They should be written in camelCase.
{
name : Main
args : (List __arglist)
Int x, List lst = []
println(__arglist, x, lst)
}
Last updated