LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Find Best Array size for n elements


@kashiruvana wrote:

Ooh, I like that. That's a good solution. (If I could mark it, I would!)


There are quite a few suggestions above, so we don't really know what you are replying to.

 

Of course you can also make my solution "all blue" (the orange square root is somewhat a blemish:)). I am sure there are even better, more faster converging integer square roots, just try it. 😄

 

 

 

 

Message 11 of 13
(737 Views)

@altenbach wrote:

@kashiruvana wrote:

Ooh, I like that. That's a good solution. (If I could mark it, I would!)


There are quite a few suggestions above, so we don't really know what you are replying to.

 

Of course you can also make my solution "all blue" (the orange square root is somewhat a blemish:)). I am sure there are even better, more faster converging integer square roots, just try it. 😄

 

 

 

 


Other than this being "all blue," are there any advantages to this approach:

 

n-m-while.png

 

Over this one:

n-m-bool.png
All I see is that as NumElements increases, the processing time will increase with the while loop while the time of the selection will be relatively constant.

0 Kudos
Message 12 of 13
(705 Views)

I would go with my q&r solution (the one with the sqrt). Easier to read than using all these compare and select nodes. Performance does not matter here.

0 Kudos
Message 13 of 13
(693 Views)