How to find the minimum value of array elements?

Hello!

I have float array with 3 elements. I need to find the minimum value of array elements. Can you show me an example?

This^

There are also these when you do not want / need to faff around with arrays:

337942-screenshot-3.png

And these can be useful when you deal with vectors:

337943-screenshot-4.png

1 Like

How to know out of that single output which one was lowest?

from my understanding. these are basically just macros that run a loop that compares each value individually. So if you need them for a different data type, just create your own macro library.

1 Like

Thanks

Here is how I was able to do it. Every float input that MIN node receives have it be a variable, and right after create a set of branches that check for = = and check those floats and you can determine exactly what float was the lowest.

The problem I am seeing with that min node is if an actor is no longer valid it doesn’t change on the inputs.

Wonder how to stack those results from greatest to least after the MIN node?

stack results? you mean basically reorder the array with the greatest value at index 0 and so on?


NVM they added a node for this

this must be new as this is the first time i’ve noticed it. but also. I feel like you need to learn how to navigate your node selection menu

all of your array nodes are sorted here. and if your context sensitive is checked and your dragging off a Float Array it will only show the nodes that are valid for float arrays.
another useful spot is MATH

Yes, exactly.

Thanks for the info.