# transformers quiz

Use functions to return values.

## Name

## Directions

Use this activity document to guide your work in the [transformers tutorial](/lessons/transformers/tutorial)

Answer the questions while completing the tutorial. Pay attention to the dialogues!

## 1. What is a 'function'?

<br/>

## 2. Write the line of code to create a number variable called **x** that is equal to 5.

<br/>

## 3. Write the line of code to create a condition for 'on button pressed ("A")'

<br/>

## 4. Write the steps to create a function.

<br/>

## 5. Create a function called **double** that will double whatever input parameter is passed into it.

<br/>

## 6. Consider the following directions. Call the function that doubles the variable original. The function is going to return the doubled value after it is called. Assign the new value (10) to a variable which we will call doubled.

<br/>

## 7. Refer to Question 6. Write the code to call the function that doubles our new variable doubled. Assign the new value 20 to a variable we will call doubled twice.

<br/>

