how is a comment statement different from other commands in kturtle ?
Answers
Answered by
5
Commands
Comments
Using commands you tell the turtle or KTurtle to do something. Some commands need input, some give output.
# forward is a command that needs input, in this case the number 100: forward 100The first line is a comment. The second line contains the forward command and the number 100. The number is not part of command, it is considered 'input' for the command.
Comments
A program consists instructions that are executed when the program is run and so called comments. Comments are not executed, KTurtle simply ignores them when executing your program. Comment are there for other programmers to make them understand your program better. Everything that follows on a # symbol is considered a comment in TurtleScript. For example this little program that does nothing:
# this little program does nothing, it is only a comment!
ishahcoudhary33:
plz mark me brainiest
Similar questions