3 ms·
Python both type and memory safe e.g., ""+1 in Python is TypeError and [][0] is IndexError But you can perform unsafe operations e.g., import ctypes c
by d0mine 2y ago
Python both type and memory safe e.g., ""+1 in Python is TypeError and [][0] is IndexError
But you can perform unsafe operations e.g.,
import ctypes
ctypes.string_at(0) # access 0 address in memory -> segfault
- eru 2y agoYes, though `ctypes' is kind of marked as `unsafe' in Python by convention.