Tensors and shapes before anything else — step 7 of 7
Checkpoint
One last thing before we move on. Same surface as a write step — but the lesson doesn't complete until this passes.
Checkpoint. The #1 tensor bug is adding two tensors whose shapes don't
match. Write add_check(a, b) that computes each tensor's shape and
returns a string saying whether an element-wise add is allowed (shapes
must be identical):
(2, 3) + (3, 2) -> shape mismatch
Use ok instead of shape mismatch when the shapes are equal.