I tried to insert a number in the string, but there was an error when I used the rest of the operations Is there any way to use % operation within %() by adding or doing something before?
python
It's working fine.
>>> a = 5
>>> b = 3
>>> 'my age,%d'%(a%b)
'my age,2'
© 2024 OneMinuteCode. All rights reserved.