Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public static float GetMax(float[] theArray)
- {
- float max = 0;
- foreach (float v in theArray)
- {
- if (v > max)
- {
- max = v;
- }
- }
- }
- public static float GetMin(float[] theArray)
- {
- float min = Mathf.Infinity;
- foreach (float v in theArray)
- {
- if (v < min)
- {
- min = v;
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment