Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Fix Indentation of f-strings example
  • Loading branch information
tusharkhatriofficial committed Sep 18, 2022
commit 173b56d497ab1624c133530666f730afd82d234d
10 changes: 5 additions & 5 deletions basics/handy-stuff-strings.md
Original file line number Diff line number Diff line change
Expand Up @@ -246,11 +246,11 @@ In this tutorial, we will focus on f-strings, which is the most common and usual

`f` in f-strings stands for "format", f-strings are string literals that have an `f` at the beginning and curly braces containing expressions that will be replaced with their values at runtime. To create f-strings, you have to add an `f` or an `F` before the opening quotes of a string.

```python
>>> f"My name is {name} and I'm on the {channel} channel on {network}."
"My name is Akuli and I'm on the ##learnpython channel on freenode."
>>>
```
```python
>>> f"My name is {name} and I'm on the {channel} channel on {network}."
"My name is Akuli and I'm on the ##learnpython channel on freenode."
>>>
```

## Other things

Expand Down