@arnauld/

Climbing grades

JavaScript

No description

fork
loading
main.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
a = ['VB','V0','V0+','V1','V2','V3','V4','V5','V6','V7','V8','V9','V10','V11','V12','V13','V14','V15','V16','V17'];

for(b = 32; b <= 36; b++) {
  for(m = 2; m < 1000; m++) {
    x = a.map(s => parseInt(s, b) % m + s);

    if((r = x.join('/')) == x.sort().join('/')) {
      console.log('Base = ' + b, 'Modulo = ' + m);
      console.log('=> ' + r);
    }
  }
}
'done'
Native Browser JavaScript