Please enable JavaScript to use CodeHS

CodeHS Glossary


setup() JavaScript

Called once when the program starts and is used to define the initial environment properties such as screen size and load any media (images, fonts, audio). There can only be one `setup()` function for each program.