Skip to content

Commit

Permalink
did hw07
Browse files Browse the repository at this point in the history
  • Loading branch information
Kettenkrado committed Apr 23, 2024
1 parent 9193499 commit 9e75423
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 7 deletions.
Binary file modified projects/hw07/.ok_history
Binary file not shown.
Binary file modified projects/hw07/.ok_storage
Binary file not shown.
14 changes: 7 additions & 7 deletions projects/hw07/hw07.scm
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,14 @@
)

(define (repeatedly-cube n x)
(if (zero? n)
x
(let
((y (repeatedly-cube (- n 1) x)))
(* y y y))))
(if (zero? n)
x
(let
((y (repeatedly-cube (- n 1) x)))
(* y y y))))

(define (cddr s) (cdr (cdr s)))

(define (cadr s) 'YOUR-CODE-HERE)
(define (cadr s) (car (cdr s)))

(define (caddr s) 'YOUR-CODE-HERE)
(define (caddr s) (car (cdr (cdr s))))
Binary file modified projects/hw07/tests/__pycache__/cadr-caddr.cpython-310.pyc
Binary file not shown.
Binary file modified projects/hw07/tests/__pycache__/pow.cpython-310.pyc
Binary file not shown.
Binary file modified projects/hw07/tests/__pycache__/repeatedly-cube.cpython-310.pyc
Binary file not shown.

0 comments on commit 9e75423

Please sign in to comment.