Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Comments Fix the syntax errors. Your Script Save Reset MATLAB Documentation % Th

ID: 3731214 • Letter: C

Question

Comments Fix the syntax errors. Your Script Save Reset MATLAB Documentation % This program calculates the amount of pasta to cook, given the number of people eating. 2 Author: Ettore Boyardee s numPeople 2 InumPeople: Number of people that will be eating totalouncesPasta-numPeople % calculate and print total ounces of pasta ouncesPer-person-% 3; Typical: 3 Run Script | Output Erzor in solution Line: 2 Column: 16 Invalid expression. Check for missing multiplication operator, missing or unbalanced delimitera, o Assessment Submit Check totalOuncesPasta's value

Explanation / Answer

% code

% Author: Ettore Boyardee

numPeople = 2; % numPeople : Number of people that will be eating

totalOuncesPasta = numPeople * 3
%{
caluculates and print total ounces of pasta
Typical: 3 ounces per person
}%

%{ EXPLANATION

Output: totalOuncesPasta = 6

If there is a one line comment, start with %, // is not for commenting in MATLAB

If multiline comment is there, then enclose the lines with %{ and }% as shown above.

}%

% code

% Author: Ettore Boyardee

numPeople = 2; % numPeople : Number of people that will be eating

totalOuncesPasta = numPeople * 3
%{
caluculates and print total ounces of pasta
Typical: 3 ounces per person
}%

%{ EXPLANATION

Output: totalOuncesPasta = 6

If there is a one line comment, start with %, // is not for commenting in MATLAB

If multiline comment is there, then enclose the lines with %{ and }% as shown above.

}%