# Examples ## Function example is used to demonstrate common writing methods of BT and help transition from basic syntax to actual scripts. ## Basic script ```bt name = 'BT' println `Hello ${name}` ``` ## Function and return value ```bt fn add(a, b) { a + b } println add(1, 2) ``` ## Traverse data ```bt for index, value in [1, 2, 3] { println value } ``` ## Web return ```bt header('Content-Type', 'application/json') json({ok: true}) ```