end

 

end is a special primitive that tells NetLogo that a procedure is finished. Just as a procedure starts with either to or to-report, it concludes with an end. A procedure that does not finish with end will cause an error.

 

Try it Yourself

 
 
 
 
 
 
 

What's next?

Once you mastered the end primitive, don't stop there. Check out the resources below to improve your NetLogo skills.

 
Published NetLogo models that use the end primitive:
 
 
Similar primitives:
to

Begins a command procedure

Read more
to-report

Begin a procedure to create a custom reporter.

Read more
ask

Asks agents to do things.

Read more
semicolon

Starts a comments to take notes on a line of code. anything that follows a semicolon (;) will not be considered code.

Read more
 
Learn another primitive: