Migrate docs from the other repo
This commit is contained in:
38
docs/reference/comment.md
Normal file
38
docs/reference/comment.md
Normal file
@ -0,0 +1,38 @@
|
||||
# Comment
|
||||
|
||||
A note in code. #docs #comment #language
|
||||
|
||||
### @parent blocks/statement
|
||||
|
||||
A comment is a line of code that contains text, usually an explanation or a note. All comments are ignored during script execution.
|
||||
|
||||
### Block
|
||||
|
||||
Right click on any block and add a comment
|
||||
|
||||
### ~hint
|
||||
|
||||
To find out how to insert comments using the Blocks editor, see [the Blocks editor](/microbit/blocks/editor).
|
||||
|
||||
### ~
|
||||
|
||||
### Sample code with comments
|
||||
|
||||

|
||||
|
||||
### Commenting out code
|
||||
|
||||
During the debugging process, you may want to comment out a section of your code so that it doesn't run.
|
||||
|
||||
To comment out a block of code:
|
||||
|
||||
1. Right click on any block of code that you want to comment out.
|
||||
|
||||
1. Select add comment
|
||||
|
||||
When you want to uncomment your code, right click the on the comment, and then click delete block.
|
||||
|
||||
### See also
|
||||
|
||||
[Block editor](/microbit/blocks/editor)
|
||||
|
Reference in New Issue
Block a user