Grain of Salt - Post a comment [entries|archive|friends|userinfo]
snauts

[ userinfo | sc userinfo ]
[ archive | journal archive ]

SICP Nov. 16th, 2010|05:06 pm

snauts
Vispār es biju redzējis, ka prologā var visādas perversijas, tur tipo:
> (append (a b) (c d) ?x)
?x = (a b c d)

> (append ?x (c d) (a b c d))
?x = (a b)

> (append (a b) ?x (a b c d))
?x = (c d)

vai:
> (append ?x ?y (a b c d))
?x = (), ?y = (a b c d)
?x = (a), ?y = (b c d)
?x = (a b), ?y = (c d)
?x = (a b c), ?y = (d)
?x = (a b c d), ?y = ()

bet tas ko es ieraudzīju SICPā ka tur var rakstīt:
> (?x (a b) (c d) (a b c d))
?x = append

mani vienkārši satrieca.
link Read Comments

Reply:
From:
Username:
Password:
Ievadi te 'qws' (liidzeklis pret spambotiem):
Subject:
No HTML allowed in subject
  
Message:

Notice! This user has turned on the option that logs IP addresses of anonymous posters.