Join us today!
Find Array Bounds
Create a generic function to find the bounds of one-dimensional array.
Inputs:
iArray (Any type of array, integer array, char array, bool array etc..)
Outputs:
isArray(Bool)
nLowerBound(Int)
nUpperBound(Int)
nNumberOfElements(Int)
If the input is an array, isArrayshould be True and other outputs should be lower bound, upper bound and the elements count in the array.
If the input is not an array, nLowerBound and nUpperBound should be -1 and isArray should be False, nNumberOfElements should be 0.
Examples:
Happy coding!
In case you want to say thank you !)
We'd be very grateful if you could share this community with your colleagues and friends. You can also buy us a coffee to keep us fueled 😊 This is the best way to say thank you to this project and support your community.
twinControls - https://twincontrols.com/
-
Array Comparison
2 years ago
-
System status light with adjustable On and Off timers
2 years ago
- 17 Forums
- 267 Topics
- 924 Posts
- 0 Online
- 737 Members