mirror of
https://github.com/markjprice/cs11dotnet7.git
synced 2025-12-06 05:32:03 +01:00
Add item for page 56
This commit is contained in:
parent
1a70251b76
commit
29c96b4523
|
|
@ -4,7 +4,7 @@ If you find any mistakes in the seventh edition, *C# 11 and .NET 7 - Modern Cros
|
|||
|
||||
[**Errata** (42 items)](errata.md): Typos, tool user interface changes, or mistakes in code that would cause a compilation error that prevents a successful build.
|
||||
|
||||
[**Improvements** (30 items)](improvements.md): Changes to text or code that would improve the content. These are optional.
|
||||
[**Improvements** (31 items)](improvements.md): Changes to text or code that would improve the content. These are optional.
|
||||
|
||||
[**Common Errors** (4 items)](common-errors.md): These are some of the most common errors that a reader might encounter when trying to get code in book tasks to work, or when trying to write your own code.
|
||||
|
||||
|
|
|
|||
|
|
@ -1,8 +1,9 @@
|
|||
**Improvements** (30 items)
|
||||
**Improvements** (31 items)
|
||||
|
||||
If you have suggestions for improvements, then please [raise an issue in this repository](https://github.com/markjprice/cs11dotnet7/issues) or email me at markjprice (at) gmail.com.
|
||||
|
||||
- [Page 25 - Adding a second project using Visual Studio 2022](#page-25---adding-a-second-project-using-visual-studio-2022)
|
||||
- [Page 56 - Examples of statements and blocks](#page-56---examples-of-statements-and-blocks)
|
||||
- [Page 69 - Raw interpolated string literals](#page-69---raw-interpolated-string-literals)
|
||||
- [Page 86 - Getting text input from the user](#page-86---getting-text-input-from-the-user)
|
||||
- [Page 128 - Rounding numbers](#page-128---rounding-numbers)
|
||||
|
|
@ -43,6 +44,23 @@ making the project name bold."
|
|||
|
||||
In the next edition, I will add a note to explicitly explain that I recommend this way of setting the startup project because it then makes it very easy to switch startup projects by simply clicking a project (or any file in a project) to make it the startup project. Although you can right-click a project and set it as a startup project, if you then want to run a different project, you must manually change it again. Simply clicking anywhere in the project is easier.
|
||||
|
||||
# Page 56 - Examples of statements and blocks
|
||||
|
||||
> Thanks to [Nickolay Chistov](https://github.com/nchistov) who raised this issue on [19 April 2023](https://github.com/markjprice/cs9dotnet5/issues/30).
|
||||
|
||||
In the next edition, I will add a note to say, "I recommend that you follow the brace-style in Microsoft official documentation. For example, the for statement, as found at the following link:
|
||||
https://learn.microsoft.com/en-us/dotnet/csharp/language-reference/statements/iteration-statements"
|
||||
```cs
|
||||
for (int i = 0; i < 3; i++)
|
||||
{
|
||||
Console.Write(i);
|
||||
}
|
||||
```
|
||||
The reason I use two spaces for indenting is because my code will be printed in a book and therefore has narrow width available.
|
||||
|
||||
The official coding style conventions are here:
|
||||
https://learn.microsoft.com/en-us/dotnet/csharp/fundamentals/coding-style/coding-conventions
|
||||
|
||||
# Page 69 - Raw interpolated string literals
|
||||
|
||||
> Thanks to [Mahdi Jaberzadeh Ansari](https://github.com/mjza) who raised this issue on [6 March 2023](https://github.com/markjprice/cs11dotnet7/issues/36).
|
||||
|
|
|
|||
Loading…
Reference in a new issue