Weird Position[list,form] behavior when used inside of Module.
- To: mathgroup at smc.vnet.net
- Subject: [mg117037] Weird Position[list,form] behavior when used inside of Module.
- From: Dwayne <dwaynedcole at gmail.com>
- Date: Tue, 8 Mar 2011 05:36:06 -0500 (EST)
This works:
Position[A, Min[A]]]
where, A = {5.3, 5.4, 5.2, 5.9}. the Position function returns ( 3 ).
But this doesn't
Module[{ A, B, RETURN},
A = Table[ F, {i,{.1, .2, .3, .4}]; (* The function F
returns {5.3, 5.4, 5.2, 5.9} *)
B = Position[A, Min[A]];
RETURN = B]
The above module returns, { }.
Is this a bug?