Строка выберите первые 2 символа Python
t = "your string"
t[:2]
TheLonelyWolf
t = "your string"
t[:2]
characters = 4
string = "This is a string"
print(string[:characters])
#output: 'This'
string = "Hello world"
string[:3] # -> Hel