Ask Question
7 September, 02:17

function summationResult = DoubleSum (s, t) % s: First summation limit (i = 1 to s) % t: Second summation limit (j = 1 to t) summationResult = 0; % Write two nested for loops to calculate the double summation % summationResult = summationResult + (i * j); end

+3
Answers (1)
  1. 7 September, 02:31
    0
    function summationResult=DoubleSum (s, t)

    summationResult=0;

    for i=1:s %first summation limit (i = 1 to s)

    for j=1:t %second summation limit (j = 1 to t)

    summationResult = summationResult + (i*j);

    end

    end

    end
Know the Answer?
Not Sure About the Answer?
Find an answer to your question 👍 “function summationResult = DoubleSum (s, t) % s: First summation limit (i = 1 to s) % t: Second summation limit (j = 1 to t) ...” in 📗 Computers & Technology if the answers seem to be not correct or there’s no answer. Try a smart search to find answers to similar questions.
Search for Other Answers