For B = np.arange(n), return the tuple (np.may_share_memory(B[::2], B[1::2]), np.shares_memory(B[::2], B[1::2])).
B = np.arange(n)
(np.may_share_memory(B[::2], B[1::2]), np.shares_memory(B[::2], B[1::2]))
Input
10
Output
(True, False)
This one's part of Premium. Unlock the full NumPy track plus every other premium problem on the site.
solve(...)