LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Max value in an array

Solved!
Go to solution

Hello,

 

Can anyone explain me why I see different max values in the attached VI.

 

I have string array, when I try to find max value using Array function I get one value, and the same string array when converted to numeric and then when I find max value I get different value? What am I not understanding here?

 

Thanks

 

0 Kudos
Message 1 of 4
(2,371 Views)
Solution
Accepted by topic author systemcrash

Repeat after me: taking the max value of a string array is a meaningless operation. Say it again.

 

Repeat after me: ASCII codes of characters are NOT the same as digit values. Say it again.

Message 2 of 4
(2,368 Views)

The point is that numbers and their string representations (that are basically a sequence of characters) are sorted differently

 

Marco

Message 3 of 4
(2,367 Views)

Thanks

0 Kudos
Message 4 of 4
(2,358 Views)