#lang racket (define (repeated f n) (define (compare f1 f2) (lambda(x) (f1 (f2 x)));lambda );compare (define (doing result n) (if (= n 1) result (doing (compare result f) (- n 1)) );if );doing (doing f n) );repeated (define (square x) (* x x) );square ((repeated square 2) 5)
最后结果: 625
时间: 2024-12-21 06:35:03