Hello Teresa,
To achieve the desired outputs, you can split each array into sub-patterns, construct them individually, and then concatenate.
For example, for output (a), you can use:
a = [eye(2), zeros(2, 1), ones(2, 2)];
Try applying a similar approach to construct the remaining outputs.
Refer to the following documentation for more information on concatenating matrices in MATLAB: