Here we will create a function that compute and print the revenue from sell n co
ID: 3838594 • Letter: H
Question
Here we will create a function that compute and print the revenue from sell n computers if we know the unit price. unitPnce. Then, run it from command window, function Revenue(n, umtPrice. Then, run it from command window. rev = n* unitPrice: fprintf('% d computers at % 3f each yields a revenue = $ %4.2f', n, unitPrice, rev); end %d print using scientific notation except for hole numbers How do we print percentage (%) or backslash () since these are used in the printing format? Double them Example: fprintf('8.9%% of the population has master degree according to ACA 03/17 n'): fprintf('This it a backsplash sign: '); Same for tingle quote. What happens when the number of % sign does not match the number of variables to print? Consider: fprintf ('% d electives, %d core courses, and %d general Ed', 4, 12, 10); What happens when we remove ", 10"? What happens when we remove and %d general Ed"? This way of the fprintf can be used to print a vector like this: fprintf('%4.2f ', -40;-34);Explanation / Answer
1. it run and show no error and value will not display
2. 1. it run and show no error and garbage value will display
3 no it give sytax error