how to clear this error?
Show older comments
Error: File: file.m Line: 103 Column: 1
Function definitions are not permitted in this context.
if true
103.function z = myfunction(Ns,8)
104.c = Ns;
105.d= 8;
106.z =f(c, d)
107.end
108.function z = f(c,d)
109. if ~mod(c,d)
110. z=0
111. else
112. z=d-mod(c,d);
113. end
114. end
115. end
Accepted Answer
More Answers (1)
Categories
Find more on Get Started with MATLAB in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!