[lang-ref] String Interpolation (Variable) ( python )

def test_string_interpolation_variable():
    # f'{x}'
    name = 'John'
    s = f'My name is {name}.'
    assert s == 'My name is John.'
def test_string_interpolation_variable_alternative():
    # '%s'
    name = 'John'
    s = 'My name is %s.' % name
    assert s == 'My name is John.'