Suppose I define:
RealVector[expr_]:=VectorQ[expr,NumberQ[#]&&Head[#]===Real)];
Then:
RealVector[{1,2,3}]; RealVector[{1.,2.,3.}];
should evaluate to False
and True
, resp. But I get False
and False
. Why?
Suppose I define:
RealVector[expr_]:=VectorQ[expr,NumberQ[#]&&Head[#]===Real)];
Then:
RealVector[{1,2,3}]; RealVector[{1.,2.,3.}];
should evaluate to False
and True
, resp. But I get False
and False
. Why?
Comments
Post a Comment