yasaminashoori / .NET-Course

C-Sharp, Asp .NET Core, SQL Server Practices
3 stars 1 forks source link

Clean code - commenting #7

Open mahdiAkhi opened 1 year ago

mahdiAkhi commented 1 year ago

// *********This is the static type class that we don't make any object and it it's general*********

This is not a good pattern to leave comments on the code!

Why are you wraitting multiple stars? If you are using Rider or Visual Studio as your IDE you can write three forward slash (///) to comment on your code. Once you typing /// the IDE will generates a standard comment template automatically.

mahdiAkhi commented 1 year ago

You can try it with a method. Just type /// on the top of the method.

/// public void PersonalInformations() { Console.WriteLine($"the student name is : {firstName}: "); }

yasaminashoori commented 1 year ago

Thank you 🌹 I'm using Visual Studio Code so I typed ctrl + / as you mentioned for comments //. And I sent the comments at the top of the program as I saw before in the projects and used prettier to format my code. I was repeating this mistake //**** so many times in my code! I resolved the problem, and I think now my code looks better and clean.