JavaScript vs OCaml
JavaScript 以 9.0 分领先于 OCaml 的 8.7 分(相差 0.3 分)。
在 15 项共同基准测试中,JavaScript 胜出 8 项,OCaml 胜出 7 项。
OCaml 在内存效率方面领先。 JavaScript 在流行度方面领先。
正面对比
共同基准测试(15)
| 基准测试 | JavaScript | OCaml |
|---|---|---|
binarytrees time (s) ↓ Programming Language Benchmarks | 0.924 | 3.02 |
lru time (s) ↓ Programming Language Benchmarks | 0.305 | 0.187 |
merkletrees time (s) ↓ Programming Language Benchmarks | 0.455 | 1.113 |
nbody time (s) ↓ Programming Language Benchmarks | 0.46 | 0.373 |
spectral-norm time (s) ↓ Programming Language Benchmarks | 2.185 | 4.574 |
binary-trees time (s) ↓ The Computer Language Benchmarks Game | 8.61 | 3.55 |
fannkuch-redux time (s) ↓ The Computer Language Benchmarks Game | 11.1 | 8.84 |
fasta time (s) ↓ The Computer Language Benchmarks Game | 2.56 | 3.37 |
k-nucleotide time (s) ↓ The Computer Language Benchmarks Game | 16.0 | 16.2 |
mandelbrot time (s) ↓ The Computer Language Benchmarks Game | 4.05 | 7.6 |
n-body time (s) ↓ The Computer Language Benchmarks Game | 8.55 | 6.95 |
pidigits time (s) ↓ The Computer Language Benchmarks Game | 1.15 | 2.77 |
regex-redux time (s) ↓ The Computer Language Benchmarks Game | 4.35 | 2.2 |
reverse-complement time (s) ↓ The Computer Language Benchmarks Game | 15.5 | 2.27 |
spectral-norm time (s) ↓ The Computer Language Benchmarks Game | 1.6 | 5.34 |