Skip to content

Bug in 2.09.scm #8

@archived-vish

Description

@archived-vish

hi @qiao ,

Inspired by your work I was trying to solve exercises in SICP & found a small issue in the solution of 2.09.scm.

; For subtraction:

FIX: if y is an interval [c d], (- y) will be an interval [-d, -c] (upper & lower bounds will flip when sign is changed). This will result in the width of (sub-interval x y) as (w1 + w2).

https://github.com/vthukral94/sicp/blob/main/chapter-2/2.8.scm#L21

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions