-
Notifications
You must be signed in to change notification settings - Fork 15
Some revisions to the cpp-tutorial lessions #60
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Besides the errors marked in the review comments, I feel like most of the changes are time-wasting and matters of taste.
There is no clear benefit to rewrite "experience compilation errors" to "end up with compilation errors". It's just a rewrite to suit one person's personal tastes over those of the original author.
wiki/cpp-tutorial/language-basics.md
Outdated
_Block comments_ start with `/*` and end with `*/`. Although they can be used for single line comments, they are | ||
typically used for comments that span multiple lines. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
_Block comments_ start with `/*` and end with `*/`. Although they can be used for single line comments, they are | |
typically used for comments that span multiple lines. | |
_Block comments_ start with `/*` and end with `*/`. Although they can be used for single-line comments, they are | |
typically used for comments that span multiple lines. |
wiki/cpp-tutorial/language-basics.md
Outdated
In above snippet, the variable `foo` is initialized with a value of `0`. The expression `foo + 2` is then | ||
evaluated, and then the result is assigned back to `foo`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In above snippet, the variable `foo` is initialized with a value of `0`. The expression `foo + 2` is then | |
evaluated, and then the result is assigned back to `foo`. | |
In the above snippet, the variable `foo` is initialized with a value of `0`. The expression `foo + 2` is then | |
evaluated, and then the result is assigned back to `foo`. |
wiki/cpp-tutorial/language-basics.md
Outdated
C++ reserves a set of words in the language for its own use. Developers may use these keywords, but they cannot be used | ||
as identifiers. You can find a list of all keywords on [cppreference](https://en.cppreference.com/w/cpp/keyword). | ||
C++ reserves a set of words in the language for its own use, known as _keywords_. These keywords may be used | ||
by developers, but they cannot be used as identifiers(such as variable name). You can find a complete list of C++ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
by developers, but they cannot be used as identifiers(such as variable name). You can find a complete list of C++ | |
by developers, but they cannot be used as identifiers (such as variable names). You can find a complete list of C++ |
wiki/cpp-tutorial/language-basics.md
Outdated
|
||
In addition to these "true keywords", C++ also has "contextual keywords", formally called _identifiers with special | ||
meaning_, such as `override`. We will cover these in later chapters. | ||
In addition to these _true keywords_, C++ also has _contextual keywords_, formally called _identifiers with special |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't see why this should be italicized. "True keywords" and "contextual keywords" are colloquial terms, and my impression is that we use italics only for proper definitions.
wiki/cpp-tutorial/language-basics.md
Outdated
## Fundamental Data Types and Literals | ||
|
||
All values in C++ have a _type_, and variables can only hold values of a specified type. | ||
In C++, every values has a _type_, and variables can only store values of the type they are declared with. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In C++, every values has a _type_, and variables can only store values of the type they are declared with. | |
In C++, all values has a _type_, and variables can only store values of the type they are declared with. |
wiki/cpp-tutorial/language-basics.md
Outdated
|
||
```cpp | ||
bool b = 1 > 0; // True if one is greater than zero. | ||
bool b = 1 > 0; // true, if 1 is greater than 0. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The added comma doesn't make sense.
wiki/cpp-tutorial/language-basics.md
Outdated
_Integer types_ in C++ are similar to whole numbers in mathematics. They can store values like `1`, `0` or `-1`, | ||
but nto fractions like 0.5. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"whole numbers" seems weird. "Integer" is also the term used in mathematics; the original was fine.
wiki/cpp-tutorial/language-basics.md
Outdated
_Integer types_ in C++ are similar to whole numbers in mathematics. They can store values like `1`, `0` or `-1`, | ||
but nto fractions like 0.5. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
_Integer types_ in C++ are similar to whole numbers in mathematics. They can store values like `1`, `0` or `-1`, | |
but nto fractions like 0.5. | |
but to fractions like `0.5`. |
b061934
to
5422fc6
Compare
Basically, some of the parts i have revised to use points rather than paragraphs but they are also just a personal preference of what i believe would be easier to read. Otherwise, all other changes should be good. |
5422fc6
to
7d81df2
Compare
* wiki/wiki/cpp-tutorial/language-basics.md: Typo and corrections to context flow Sign off: Magnus-Mage <>
7d81df2
to
844c096
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should be fine with the fomratting now
Files changed:
Sign off: Magnus-Mage <>