The Computer Language
Benchmarks Game

Python 3 versus Node js fastest programs

Always look at the source code.

These are only the fastest programs. Do some of them use manually vectorized SIMD? Look at the other programs. They may seem more-like a fair comparison to you.

regex-redux
source secs mem gz busy cpu load
Python 3 1.36 111,852 1403 2.64 32% 40% 33% 88%
Node js 4.64 1,163,148 668 5.83 3% 14% 30% 79%
pidigits
source secs mem gz busy cpu load
Python 3 1.28 12,024 567 1.29 0% 1% 100% 0%
Node js 1.29 37,068 599 1.36 1% 100% 2% 2%
k-nucleotide
source secs mem gz busy cpu load
Python 3 46.28 241,108 1967 176.42 94% 97% 95% 96%
Node js 15.68 397,548 1812 44.40 82% 95% 44% 62%
reverse-complement
source secs mem gz busy cpu load
Python 3 7.20 1,005,184 814 10.75 20% 53% 48% 29%
Node js 2.17 1,535,512 1480 4.64 62% 53% 56% 42%
binary-trees
source secs mem gz busy cpu load
Python 3 51.07 278,324 589 178.28 85% 86% 93% 85%
Node js 7.52 1,343,968 744 22.37 73% 70% 85% 69%
fasta
source secs mem gz busy cpu load
Python 3 37.32 846,264 1947 71.03 10% 67% 83% 30%
Node js 1.89 71,820 2047 6.13 79% 79% 81% 85%
fannkuch-redux
source secs mem gz busy cpu load
Python 3 352.29 12,232 950 1,392.10 97% 99% 100% 99%
Node js 11.60 64,024 1313 45.89 99% 99% 99% 99%
mandelbrot
source secs mem gz busy cpu load
Python 3 163.32 12,080 688 642.00 98% 98% 98% 98%
Node js 4.03 95,448 1122 15.91 99% 98% 99% 100%
n-body
source secs mem gz busy cpu load
Python 3 567.56 8,076 1196 570.95 0% 0% 0% 100%
Node js 8.63 36,136 1268 8.67 0% 0% 100% 0%
spectral-norm
source secs mem gz busy cpu load
Python 3 120.99 13,424 407 479.86 99% 99% 99% 99%
Node js 1.64 67,584 999 6.12 92% 92% 93% 95%
Python 3

Python 3.9.2

Node js

v16.3.0