Course of Raku / Essentials / Strings / Variable interpolation

# Quiz: String interpolation

Select the strings, where the value of `$x`

is interpolated exactly one time.

1 | "The temperature is $x degrees" | |

0 | 'Air pressure is $x mmHg' | No interpolation in single quotes. |

0 | 'The value of \$x is $x' | No interpolation and no escaping. It prints `The value of \$x is $x` . |

1 | "The value of \$x is $x" | The whole phrase gives, for example, `The value of $x is 42` . |

0 | "The value of $x is $x" | `$x` is interpolated twice here. |

## Course navigation

← Strings / String concatenation | Strings / Code interpolation →

💪 Or jump directly to the exercises to this section.

Translations of this page: **English** • Deutsch • Español • Italiano • Latviešu • Nederlands • Български • Русский • Українська