if at least one number >

I have A=[ 11 12 17]
number=13; W={}; if (A>=number)
W{1}{1}=A;
else
A;
end
I want it so that if there was at least one number in A > as number,then A stored in cell W
Thanks

 Accepted Answer

A=[ 11 12 17]
number=13;
W={};
if any(A>number)
W{1}=A;
end

More Answers (0)

Categories

Find more on Quantum Mechanics in Help Center and File Exchange

Tags

Asked:

on 23 Nov 2013

Commented:

on 23 Nov 2013

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!