> For the complete documentation index, see [llms.txt](https://help.trikset.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.trikset.com/en/trik-studio-junior/visual-programming.md).

# Visual programming in TRIK Studio Junior

A program in the TRIK Studio Junior is represented as a sequence of the [blocks](/en/trik-studio-junior/visual-programming/blocks.md) connected by the [links](/en/trik-studio-junior/visual-programming/connection-between-blocks.md).&#x20;

![](https://2483351831-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M-9YMGCK0ySSnTAiseS%2F-MTavFkCgLD4YKa3rOh_%2F-MTavSTqmbFKGi4HjXJd%2F14-1%20En%20blocks%202.png?alt=media\&token=b6acb6b4-8701-48b6-86c7-aa74561bca0a)

Each program corresponds to the [main diagram](/en/trik-studio-junior/visual-programming.md#main-diagram), which may contain other [diagrams (subprograms)](/en/trik-studio-junior/visual-programming.md#subprograms). Diagrams are packaged in projects stored on the disk.

![](https://2483351831-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M-9YMGCK0ySSnTAiseS%2F-MTavFkCgLD4YKa3rOh_%2F-MTavVgM7wfBj7TAmlaL%2F14-2%20En%20diagram%203.png?alt=media\&token=6e420ae1-ed47-49d0-94b0-9332ac59f9d7)

## Main diagram <a href="#main-diagram" id="main-diagram"></a>

The main diagram is created when the [project is created](/en/trik-studio-junior/start.md#project-creation). About adding and removing blocks to the [scene](/en/studio/interface.md#editor-window), read the article:

{% content-ref url="/pages/-MaDT\_3h6e4aB0nq3K5u" %}
[Adding and removing blocks in TRIK Studio Junior](/en/trik-studio-junior/visual-programming/blocks-add-delete.md)
{% endcontent-ref %}

## Subprograms

The diagrams with subprograms are created automatically when you add the block "Subprogram" to the scene. In this case, the subprogram is displayed by double-clicking on the "Subprogram" block on the scene.

![](https://2483351831-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M-9YMGCK0ySSnTAiseS%2F-MTavFkCgLD4YKa3rOh_%2F-MTavax1O3micIpXbk3P%2F14-3%20En%20subprogramm.gif?alt=media\&token=f65c8df5-b0bc-4f14-9178-be4f5c6213f0)

Read more about subprograms in the article:

{% content-ref url="/pages/-MaDUL4gQGbZYW0bO9Mr" %}
[Subprograms in TRIK Studio Junior](/en/trik-studio-junior/visual-programming/subprograms.md)
{% endcontent-ref %}
