---
ref: http://robotframework.org/robotframework/4.0.1/RobotFrameworkUserGuide.html#simple-for-loop
update: 2021-12-20
---

# For

```robot
*** Test Cases ***
Example Inline
    FOR    ${animal}    IN    cat    dog
        Log    ${animal}
    END
```

For list variables,
prepend it with `@`.

```robot
*** Test Cases ***
Example List Variable
    FOR    ${element}    IN    @{ELEMENTS}
        Log    ${element}
        IF    Condition Satisfied
            Exit For Loop
        END
    END
```

---
ref: http://robotframework.org/robotframework/4.0.1/RobotFrameworkUserGuide.html#simple-for-loop
update: 2022-02-28
---

# For

```robot
*** Test Cases ***
Example Inline
    FOR    ${animal}    IN    cat    dog
        Log    ${animal}
    END
```

For list variables,
prepend it with `@`.

```robot
*** Test Cases ***
Example List Variable
    FOR    ${element}    IN    @{ELEMENTS}
        Log    ${element}
        IF    Condition Satisfied
            Exit For Loop
        END
    END
```

## In-range

```robot
*** Test Cases ***
Only upper limit
    [Documentation]    Loops over values from 0 to 9
    FOR    ${index}    IN RANGE    10
        Log    ${index}
    END
```

Add robot framework for in range note
Add robot framework for in range note
