Prompt the user for an integer n and print “I love this stuff!” n times
belongs to book: MATLAB: A Practical Introduction to Programming and Problem Solving|Stormy Attaway|Fourth Edition| Chapter number:5| Question number:3.5
All Answers
total answers (1)
Ch5Ex3.m
% Prompts the user for an integer n and prints
% "I love this stuff" n times
n = input('Enter an integer: ');
for i = 1:n
disp('I love this stuff!')
end
need an explanation for this answer? contact us directly to get an explanation for this answer