modified js pyramid and js fib