Answer the question
In order to leave comments, you need to log in
Rationality of C# code?
Recently started learning C#. Wrote r##no-code for a simple game according to the task. All that I wanted to start - realized. But after viewing the code, and even while writing it, there was a feeling that perhaps somehow I was not rationally using cycles, operations, and it was possible to write them more compactly without making thousands of conditions. Consider commenting on each line to make it more readable. I would like to hear what mistakes I made in order to avoid them in the future.
Code - https://paste.ofcode.org/ZWDFWib4cZff4Y8Nf5ZyCk
Answer the question
In order to leave comments, you need to log in
Of course, after watching a thousand different things, I want to say. And about non-modularity in your code, and about not using constants, which, by their use, make unnecessary code commenting, etc. But. For a prototype, it's ok. And the fact that you reflect what you created is also good.
You need to study or at least read about it:
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question