Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Question 5 1 0 pts What does counter 2 provide at the end of this script? x = [ - 1 0 1 - 3

Question 5
10 pts
What does counter 2 provide at the end of this script?
x=[-101-3037-16]
counter 1=0;
counter 2=0;
for i=1 :length (x)
if x(i)0
counter 1= counter 1+1
elseif x(i)=0
counter 2= counter 2+1
end
end
The number of zeros and the number of negative numbers in vector x
The number of negative and positive numbers in vector x
The number of elements in vector x that are non-zero and non-negative (i.e. positive)
The number of nonzero elements in vector x
image text in transcribed

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

OCA Oracle Database SQL Exam Guide Exam 1Z0-071

Authors: Steve O'Hearn

1st Edition

1259585492, 978-1259585494

More Books

Students also viewed these Databases questions

Question

Th ey told me Id have to write a lett er. Whos got time for that?

Answered: 1 week ago

Question

3. Is IBMs program really a mentoring program? Why or why not?

Answered: 1 week ago