Last answered:

20 Oct 2022

Posted on:

12 Dec 2021


can you explain why i got this error message after replacing the comma with (+)???


2 answers ( 0 marked as helpful)
Posted on:

14 Sept 2022


Hi! It's because the Numbers variable is an integer. When try to concatenate strings with an integer using the "+" sign, Python interprets it as an arithmetic sign instead of concatenation. You would either have to use commas or transform your integer into a string.

Posted on:

20 Oct 2022


Hi Asmaa Abdulhamid
use this code instead:
print('The fourth element of the numbers list is:' + str(Numbers[3]) + '.')

Submit an answer