@ Pohon BBS

Last 25 posts

18. exercise 1.3
Published: 2026-09-09 [Wed] 20:55, by clouds
>>4
[(define (square a)
(* a a))

(define (smallest x y z)
(if (< x y)
(if (< x z) x z)
(if (< y z) y z)))

(define (procedure x y z)
(- (+ (square x)(square y)(square z))(square (smallest x y z))))

(procedure 7 10 10)]
.
17. epic phail
Published: 2026-09-09 [Wed] 15:35, by Anonymous
>>16
Fixed the fix

#lang sicp

(define (square x) (* x x))

(define (sicp_ex_1.3 x y z)
(+
(if (= x y z) 0
(if (< x y) (if (< x z) 0 (square x)) (square x))))
(if (< y x) (if (< y z) 0 (square y)) (square y))
(if (< z y) (if (< z x) 0 (square z)) (square z)))

(sicp_ex_1.3 1 2 3)
(sicp_ex_1.3 2 2 2)
(sicp_ex_1.3 2 1 0)
.
16. fix ex 1.3
Published: 2026-09-09 [Wed] 15:27, by PhatCat
>>14
summed all 3 squares if x y z were the same. added a check to just force one variable to zero if all the numbers were equal so theres probably a more elegant solution :P. Code:

#lang sicp

(define (square x) (* x x))

(define (sicp_ex_1.3 x y z)
(+
(if (= x y) 0 (if (= x z) 0
(if (< x y) (if (< x z) 0 (square x)) (square x))))
(if (< y x) (if (< y z) 0 (square y)) (square y))
(if (< z y) (if (< z x) 0 (square z)) (square z))))

(sicp_ex_1.3 1 2 3)
(sicp_ex_1.3 2 2 2)
(sicp_ex_1.3 2 1 0)
.
49. Spoiler hack (temporary)
Published: 2026-09-09 [Wed] 05:15, by Archduke◆cRwJk8JEBs
I am too lazy to make a proper "spoiler field" (similar to markdown's
code fences) to spoiler-ify multiple lines of text right this second, so if
you need to make an entire post a spoiler post, do it exactly like this:

%%%
The text you want to hide across multiple
lines -- the entire body of a post
%%%

That's 3 %'s at the very start of a post,
immediately press enter to break the line,
everything else,
enter,
3 %'s again with nothing following.

Later I'll probably just add a [ ] Spoiler checkbox but I've been up for
something like 30 hours and now is not the time for that. Be patient!
enjoy and use responsibly!
.
14. Excercise 1.3
Published: 2026-09-09 [Wed] 01:43, by PhatCat
>>13
My attempt at exercise 1.3. it took me a long time as most of my attempts made code that excluded anything that wasn't the maximum number, so i guess finding the "middle" number is what makes this challenging. my first attempts were checking each variable against the others individually (mistake). if x>y then output x otherwise 0, if x>z output x otherwise 0 then multiply both outputs, repeat for each variable (rather silly in retrospect). After this i decided to only compare to the third variable if the first check failed and directly compute the square if the variable wasn't the minimum. Code below:

#lang sicp
(define (sicp_ex_1.3 x y z)
(+
(if (< x y) (if (< x z) 0 (* x x)) (* x x))
(if (< y x) (if (< y z) 0 (* y y)) (* y y))
(if (< z y) (if (< z x) 0 (* z z)) (* z z))))

(sicp_ex_1.3 1 2 3)
result was 13 so it worked
.
12.
Published: 2026-09-08 [Tue] 20:11, by Anonymous
>>3
Famous article by a guy who used Lisp to become a billionaire :

> Graham, Paul. "The Roots of Lisp." (2001) 15pp
https://wiki.eecs.yorku.ca/course_archive/2014-15/W/6339/_media/jmc.pdf

discusses how 7 primitives became the meta language
.
10. outputs color based on stats (hopefully)
Published: 2026-09-08 [Tue] 19:37, by PhatCat
>>3
(define (clouds_color strength intelligence Defense)
(define red strength)
(define blue intelligence)
(define green defence)
(list red green blue))) % gives RGB color (idk how to/
if its even possible for lisp to output a color)
.
9. Chapter 5
Published: 2026-09-08 [Tue] 19:30, by Anonymous
> Computing with Register Machines

https://mitp-content-server.mit.edu/books/content/sectbyfn/books_pres_0/6515/sicp.zip/full-text/book/book-Z-H-30.html#%_chap_5
.
8. Chapter 4
Published: 2026-09-08 [Tue] 19:29, by Anonymous
> Metalinguistic Abstraction
https://mitp-content-server.mit.edu/books/content/sectbyfn/books_pres_0/6515/sicp.zip/full-text/book/book-Z-H-25.html#%_chap_4
.
7. Chapter 3
Published: 2026-09-08 [Tue] 19:28, by Anonymous
> Modularity, Objects, and State

https://mitp-content-server.mit.edu/books/content/sectbyfn/books_pres_0/6515/sicp.zip/full-text/book/book-Z-H-19.html#%_chap_3
.
6. Chapter 2
Published: 2026-09-08 [Tue] 19:27, by Anonymous
> Building Abstractions with Data
https://mitp-content-server.mit.edu/books/content/sectbyfn/books_pres_0/6515/sicp.zip/full-text/book/book-Z-H-13.html#%_chap_2
.
5. phatcat power level formula (first scheme test)
Published: 2026-09-08 [Tue] 19:24, by clouds
>>3
(define phatcat_powerlevel 1200)
(define unlocked_potential 500)
(define (phatcat_bulky_transformation x y) (* 1.2 (+ x y)))
(phatcat_bulky_transformation phatcat_powerlevel unlocked_potential)
.
4. Chapter 1
Published: 2026-09-08 [Tue] 19:21, by Anonymous
SICP chapter 1
> Building Abstractions with Procedures

https://mitp-content-server.mit.edu/books/content/sectbyfn/books_pres_0/6515/sicp.zip/full-text/book/book-Z-H-9.html#%_chap_1
.
3.
Published: 2026-09-08 [Tue] 19:20, by Anonymous
Random Scheme / Lisp / programming discussion that doesn't fit into
chapter discussion goes here....
.
2.
Published: 2026-09-08 [Tue] 19:19, by Anonymous
General Scheme troubleshooting / installation help / etc goes under this
comment....
.
1. SICP : Let's Read!
Published: 2026-09-08 [Tue] 19:18, by piper
> SICP Book:
https://mitp-content-server.mit.edu/books/content/sectbyfn/books_pres_0/6515/sicp.zip/full-text/book/book-Z-H-4.html

> SICP Lectures:
https://www.youtube.com/playlist?list=PLE18841CABEA24090
> Racket Scheme
https://racket-lang.org/download/
> SICP Racket
https://docs.racket-lang.org/sicp-manual/Installation.html

Let's embrace the tree structure of Pohon BBS.

Top level comments for chapters of the book,
replies to top level comments for discussions of the chapter.

Comment #2 will be for general help installing Scheme
Comment #3 will be for random Scheme discussion that doesn't
fit into chapter discussion.

Ready, start, go!
.
1. A man has fallen into BAD END in sea city!
Published: 2026-07-28 [Tue] 10:40, by Athletic_giko
@Admin today i was just going about my day peacefully sending GOATSE to soyteens when some (handsome) dark boon joined with the name BANNER and proceeded to call me a nerd and ban me! As CEO of giko, it is your responsibility to do something about this ASAP. I've already received many phone calls from concerned sea citizens, many of which are refusing to leave their homes while this hit and run banner roams the streets freely!
.
6.
Published: 2026-07-27 [Mon] 16:12, by Anonymous
Movie theater!!!
.
5.
Published: 2026-07-15 [Wed] 16:32, by Anonymous
♂gay sex fisting dungeon♂
.
4.
Published: 2026-07-08 [Wed] 05:32, by Anonymous
>>3
>>3
i'm titillated piqued and intrigued
.
13.
Published: 2026-07-08 [Wed] 05:30, by Anonymous
found some untrod (by me) forest park trails
.
5.
Published: 2026-07-01 [Wed] 16:49, by Anonymous
What were your favorite historic sites you visited?
.
8. Woman in the Dunes
Published: 2026-06-26 [Fri] 22:41, by Anonymous
comfy PDF and ready-to-book PDF files :
https://freebeerextremist.com/notice/B7jKJtlduNpfAdnm3U
.
1. MittensEdit / Killsushi
Published: 2026-06-17 [Wed] 20:10, by Anonymous
dear friend killsushi passed away
https://4-ch.net/general/kareha.pl/1780712927/

But he left us a cool new SJIS editor:
https://services.4-ch.net/editor/Instructions.html
.
Pohon BBS