Gidsss / UwUIDE

A compiler made to be cute uwu >~<
6 stars 0 forks source link

TypeError: string indices must be integers, not 'Int' #260

Closed uzuriel closed 4 months ago

uzuriel commented 4 months ago

fwunc mainuwu-san() [[ str-senpai = inpwt("Enter words/phrases/sentences: ")~ fow(i-chan=0~ i<str.len()~ i++) [[ iwf ((str.len() - 1) == i) [[ pwint(str{i})~ ]] ]] ]]

got this error:

Enter words/phrases/sentences: hello Traceback (most recent call last): File "C:\Users\Sean\AppData\Local\Temp\tmp1lnrbqmm.py", line 652, in main() File "C:\Users\Sean\AppData\Local\Temp\tmp1lnrbqmm.py", line 640, in main print(_str[Int(_i)]) ~~^^^^^^^^^ File "C:\Users\Sean\AppData\Local\Temp\tmp1lnrbqmm.py", line 64, in getitem return self.val[index] ~~^^^^^^^ TypeError: string indices must be integers, not 'Int'