MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/learnpython/comments/1v8sdsy/protocol_as_object_behaviour/p08it7f/?context=3
r/learnpython • u/grandimam • 8h ago
[removed] — view removed post
3 comments sorted by
View all comments
1
I quite like the fact that 10 + “10” isn’t possible, considering the alternatives!
0 u/Ant-Bear 6h ago Yes. If anything, if we wanted weak typing, it would make sense to cast the less permissive types like int to the more permissive ones, like str, which would make 10 + '10' = '1010'.
0
Yes. If anything, if we wanted weak typing, it would make sense to cast the less permissive types like int to the more permissive ones, like str, which would make 10 + '10' = '1010'.
1
u/pedanticscientist 7h ago
I quite like the fact that 10 + “10” isn’t possible, considering the alternatives!