# Your first app

Here is a complete app: a counter with a header and a round + button. Press **Try it**, or copy it into src/main.vi, and watch the phone update. Notice the three parts: data at the top, a function that changes the data, and containers that draw the screen. (Real projects split these parts into files; the lesson **Files and projects** shows how.)

```vi
# Data
count = 0

# Functions
increment():
  count = count + 1

# The screen
main main_screen:
  color: white
  children:
    header:
      size: max, 12
      color: purple[300]
      arrange: center
      children:
        header_text:
          text: "Simple Counter App"
          text_style: 16, bold
    body:
      size: max, max
      arrange: center
      children:
        counter:
          size: 30
          shape: rounded
          color: purple[600]
          arrange: center
          text: "{count}"
          text_style: 32, white
        fab:
          place: bottom right
          size: 15
          space_around: 16
          shape: circle
          color: blue
          arrange: center
          on_tap: increment()
          children:
            plus:
              icon: plus
              text_style: 28, white
```
