-
Notifications
You must be signed in to change notification settings - Fork 171
Closed
Description
The following code:
def f():
s: str
s = "abcdefg"
print(s[1]) # prints "bcdefg", but should print "b"
print(s[1:2]) # prints "cdefg", but should print "b"
print(s[1:3]) # prints "defg", but should print "bc"
f()Prints (correctly) using CPython:
$ python a.py
b
b
bcBut with LPython it prints:
$ lpython a.py && ./a.out
bcdefg
cdefg
defgWe have to fix it.
Metadata
Metadata
Assignees
Labels
No labels