Libraryless. Click here for Pure Java version (44L/1K).
static int absDoubleMaxIndex(double[] l, int from, int to) { double max = -Double.MAX_VALUE; int idx = -1; for (int i = from; i < to; i++) { double d = abs(l[i]); if (d > max) { max = d; idx = i; } } ret idx; }
Began life as a copy of #1031939
download show line numbers debug dex old transpilations
Travelled to 3 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx
No comments. add comment
| Snippet ID: | #1031940 |
| Snippet name: | absDoubleMaxIndex |
| Eternal ID of this version: | #1031940/3 |
| Text MD5: | 517ff69350b61df970c6677e42dce1a0 |
| Transpilation MD5: | 43e9b3aff8ad9dcabaee7efd411caf08 |
| Author: | stefan |
| Category: | javax |
| Type: | JavaX fragment (include) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2021-08-03 17:13:36 |
| Source code size: | 255 bytes / 12 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 394 / 492 |
| Version history: | 2 change(s) |
| Referenced in: | #1006654 - Standard functions list 2 (LIVE, continuation of #761) |