In the following mwe visual studio code
seems to be unable to realize the type.
Using mouse-over shows the type of testa
as str
and testb
as float
which is correct.
Using mouse-over on aelem
or belem
no type is recognized.
I wonder why.
import typing
def MWE(a: typing.List[str], b: typing.List[float]) -> None:
testa=a[0]
testb=b[0]
print(f"{testa} und {testb}")
for aelem, belem in zip(a,b):
aelem.rfind("/")
round(belem)
MWE(['a','b'], [1.0,2.0])