using matlab Create name function described below: Function name should be probl
ID: 3864839 • Letter: U
Question
using matlab
Explanation / Answer
Matlab code:-
Note:- The matleb code ie explained with comments followed by %
function [ result,loop_counter ] = problem_3(iterations,the_number) % function named problem_2 takes two input and two output arguments
for loop_counter=1:iterations % for loop to repeat for iterations number of times from 1 to iterations
the_number=the_number+loop_counter; % during each iteration the current value of loop_counter is added to the_number
end
result=the_number; % the value of the number is stored in result
end
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.