Creating the M-File
To get started, create the M-file mymagic.m containing the following code:
mymagic.m
function y = mymagic(x) y = magic(x);