Unformatted text preview: receives data % % synopsis %  initialize %  read and accumulate the data %  print result % clear % initialize sum = 0; % read and accumulate the data for i = 1:5 x(i) = input('Enter datum: ') sum = sum + x(i); sum % debug / demo end e % print result disp(['the sum of the five values is ' num2str(sum)])...
View
Full Document
 Spring '10
 mustafa
 Vector Space, 2000 g, vectors sum scalar

Click to edit the document details