Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Problem 1.3 Write a function named sumnots that computes the sum of all entries of the input matrix that are not equal to 3. Function

image text in transcribed

Problem 1.3 Write a function named sumnots that computes the sum of all entries of the input matrix that are not equal to 3. Function Save C Reset DI MATLAB Documentation 1 function mod_sum = sumnot3(A) 2 [rows cols] = size(A); 3 mod_sum = 0.0; 4 % code to add to mod_sum entries of A not equal to 3 5 end Code to call your function C Reset 1 sumnot3([1 2 3; 4 5 6; 7 8 9]) 2 sumnot3([3 3 3 3; 3 3 3 3]) 3 sumnot3(1 1 1 1; 1 1 1 1]) % correct answer 1+2+4+5+6+7+8+9=42 % correct answer o % correct answer 8

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Microsoft SQL Server 2012 Unleashed

Authors: Ray Rankins, Paul Bertucci

1st Edition

0133408507, 9780133408508

More Books

Students also viewed these Databases questions