00:01:50 -!- RageOfThou [n=RageOfTh@92.36.162.136] has quit [Read error: 104 (Connection reset by peer)] 00:01:57 FunkyDrummer [n=RageOfTh@92.36.162.136] has joined #scheme 00:03:28 -!- FunkyDrummer [n=RageOfTh@92.36.162.136] has quit [Read error: 104 (Connection reset by peer)] 00:03:42 FunkyDrummer [n=RageOfTh@92.36.162.136] has joined #scheme 00:03:54 (let loop () (let ((line (read-line))) (if (eof-object? line) (void) (begin (do-something-with line) (loop)))) 00:05:21 I'm not sure how the reference for some generic looping shortcut macros helps someone learn how to read in a file one line at a time... 00:07:29 the generic looping construct has an iterator over lines 00:11:41 -!- FunkyDrummer [n=RageOfTh@92.36.162.136] has quit [Read error: 104 (Connection reset by peer)] 00:11:55 FunkyDrummer [n=RageOfTh@92.36.162.136] has joined #scheme 00:28:10 -!- saccade_ [n=saccade@18.188.70.132] has quit ["This computer has gone to sleep"] 00:29:34 Adamant [n=Adamant@c-76-29-188-22.hsd1.ga.comcast.net] has joined #scheme 00:32:27 hm, the generic loopers do look shiny, but I would up defining a recursive reader instead 00:45:14 Modius [n=Modius@adsl-69-150-57-149.dsl.austtx.swbell.net] has joined #scheme 00:47:28 JasonPx [n=Jason@ipanema.parkpointrit.com] has joined #scheme 00:47:28 -!- JasonPhD [n=Jason@ipanema.parkpointrit.com] has quit [Read error: 54 (Connection reset by peer)] 00:47:41 -!- Modius [n=Modius@adsl-69-150-57-149.dsl.austtx.swbell.net] has quit [Client Quit] 00:48:00 Modius [n=Modius@adsl-69-150-57-149.dsl.austtx.swbell.net] has joined #scheme 00:49:54 -!- raikov [n=igr@203.181.243.11] has quit [Remote closed the connection] 00:50:35 anyone here experienced in plt's typed scheme? 00:51:24 -!- davidad [n=me@RANDOM-ONE-NINETY-SEVEN.MIT.EDU] has quit [Connection timed out] 00:51:40 if I have a 'local' function definition, how do I give a type to that ? 00:54:31 define/contract ? 00:55:16 oh, really types, not contracts 00:55:53 davidad [n=me@RANDOM-THREE-SEVENTY-SEVEN.MIT.EDU] has joined #scheme 00:56:01 yeah I don't see any docs of how to give a type to a 'local' function definition 00:59:12 well, quickly playing around it seems that it's exactly the same as for top level defines 01:00:27 p1d pasted "typed inner procedures" at http://paste.lisp.org/display/78722 01:00:45 inforichland: ^^ 01:02:38 -!- MichaelRaskin [n=MichaelR@gwh-1-177-mytn23k1.ln.rinet.ru] has left #scheme 01:02:47 -!- jonrafkind [n=jon@crystalis.cs.utah.edu] has quit [Read error: 60 (Operation timed out)] 01:03:02 MichaelRaskin [n=MichaelR@gwh-1-177-mytn23k1.ln.rinet.ru] has joined #scheme 01:03:19 p1dzkl: thanks 01:03:37 but i have a definition like this: 01:03:38 (local [(define (rec s pairs) 01:03:43 etc. 01:03:48 i guess i'll have to play around with it 01:05:28 JasonPhD [n=Jason@ipanema.parkpointrit.com] has joined #scheme 01:06:32 GreyLensman [n=ray@c-76-108-236-161.hsd1.fl.comcast.net] has joined #scheme 01:06:47 -!- GreyLensman [n=ray@c-76-108-236-161.hsd1.fl.comcast.net] has left #scheme 01:09:21 Trollinator [n=foo@g226231019.adsl.alicedsl.de] has joined #scheme 01:09:29 is there a function that appends a value to a list? 01:09:40 like cons, but backwars 01:09:50 trollinator: append 01:10:01 append appends a list to another list. 01:10:05 -!- FunkyDrummer [n=RageOfTh@92.36.162.136] has quit [Read error: 110 (Connection timed out)] 01:10:39 yup 01:10:47 so, you have to go: (append (list 2 3) (list 1)) 01:10:53 to append 1 to the end 01:10:54 OK. 01:11:36 strange. 01:11:42 there's a cons, but no snoc 01:12:38 (define (snoc p) (values (car p) (cdr p))) surely 01:12:44 -!- JasonPx [n=Jason@ipanema.parkpointrit.com] has quit [Read error: 60 (Operation timed out)] 01:14:53 -!- mejja [n=user@c-f6b6e555.023-82-73746f38.cust.bredbandsbolaget.se] has quit [Remote closed the connection] 01:16:14 arcfide [n=arcfide@adsl-99-50-230-39.dsl.bltnin.sbcglobal.net] has joined #scheme 01:16:24 p1d annotated #78722 "typed local procedures" at http://paste.lisp.org/display/78722#1 01:17:06 I still don't see the problem inforichland ? 01:17:46 p1dzkl: I figured it out 01:18:06 but now I have an untyped variable in a macro expansion 01:19:38 oh well I can redefine it 01:21:48 p1dzkl: do you know if typed-scheme gives any speedups? in most statically typed languages, the compiler already knows the types, so it can dramatically speed up the code 01:26:53 -!- andrei [n=user@c-98-223-64-197.hsd1.in.comcast.net] has left #scheme 01:28:46 -!- MichaelRaskin [n=MichaelR@gwh-1-177-mytn23k1.ln.rinet.ru] has left #scheme 01:29:53 MichaelRaskin [n=MichaelR@gwh-1-177-mytn23k1.ln.rinet.ru] has joined #scheme 01:30:40 hmmm hwo do i check if a thing is a list? 01:30:46 i tried (list? (list 12 3)) 01:31:01 but i get an error 01:32:42 jcowan [n=jcowan@dsl-67-158-180-34.taconic.net] has joined #scheme 01:36:29 jasonphd: (cons? (list 12 3)) 01:37:09 is another way 01:37:12 -!- Trollinator [n=foo@g226231019.adsl.alicedsl.de] has quit [Remote closed the connection] 01:37:17 but plt scheme does have a list? function 01:37:39 cons? is the more standard way to check for a list, IIRC 01:37:55 since, technically, There Is No List ;) 01:38:21 list? is in R5RS 01:38:41 and I have no idea about speedups 01:38:51 p1dzkl: ok 01:39:04 sorry, I'm in-between CL and plt scheme 01:39:08 and sometimes I get mixed-up 01:40:49 it's consp in cl 01:41:15 well then if scheme has both, what's the difference between cons? and list? 01:41:26 a list is just nested cons cells 01:41:54 a list is some nested cons cells terminated with '() 01:42:04 oh, hmm, (list? '(1 . 2)) is #f, but (cons? '(1 . 2)) is #t 01:42:08 right 01:43:53 hmm, is there any way to use typed-scheme and scheme/gui together ? 01:45:48 -!- synx [i=synx@gateway/gpg-tor/key-0xA71B0C6A] has quit [Remote closed the connection] 01:48:13 -!- inforichland [n=inforich@96-42-29-58.dhcp.mdsn.wi.charter.com] has quit [Remote closed the connection] 01:48:29 inforichland [n=inforich@96-42-29-58.dhcp.mdsn.wi.charter.com] has joined #scheme 01:50:20 synx [i=synx@gateway/gpg-tor/key-0xA71B0C6A] has joined #scheme 01:50:23 Actually it's pair? in Scheme and consp in CL 01:51:27 at least plt scheme has a cons? functino 01:51:29 function* 01:52:24 metasyntax [n=taylor@pool-71-127-85-87.aubnin.fios.verizon.net] has joined #scheme 01:53:01 -!- annodomini [n=lambda@wikipedia/lambda] has quit [Read error: 104 (Connection reset by peer)] 01:54:30 ffd [n=ffd@cpe-24-27-73-108.tx.res.rr.com] has joined #scheme 01:55:27 araujo [n=araujo@gentoo/developer/araujo] has joined #scheme 01:56:54 huh, weird... 01:57:03 rudybot: eval (eq? cons? pair?) 01:57:04 synx: your scheme sandbox is ready 01:57:05 synx: ; Value: #f 01:57:19 rudybot: eval (cons? '(1 . 2)) 01:57:19 synx: ; Value: #t 01:57:24 rudybot: eval (cons? '(1 2)) 01:57:25 synx: ; Value: #t 01:57:36 rudybot: eval (cons? 12) 01:57:37 synx: ; Value: #f 01:57:51 very weird. 02:00:25 You can't count on eq-ness of functions. 02:03:55 bhrgunatha [n=chatzill@118-170-43-101.dynamic.hinet.net] has joined #scheme 02:04:07 -!- bhrgunatha [n=chatzill@118-170-43-101.dynamic.hinet.net] has quit [Remote closed the connection] 02:06:26 anyone know of a scheme implemented in forth? 02:08:35 bhrgunatha [n=chatzill@118-170-43-101.dynamic.hinet.net] has joined #scheme 02:11:01 -!- Adamant [n=Adamant@unaffiliated/adamant] has quit [] 02:11:28 are they the same function though jcowan? 02:11:29 I don't know of any way to check that. 02:11:42 That's the halting problem. 02:12:34 -!- bhrgunatha [n=chatzill@118-170-43-101.dynamic.hinet.net] has quit [Client Quit] 02:13:02 Adamant [n=Adamant@c-76-29-188-22.hsd1.ga.comcast.net] has joined #scheme 02:13:34 That's if two functions both have the same result. 02:14:01 I mean if it's the same function with the same code. Not even necessarily the same result. 02:14:35 rudybot: eval (values (eq? random random) (= (random 10) (random 10))) 02:14:35 synx: ; Value: #t 02:14:36 synx: ; Value#2: #f 02:16:14 Seemingly it is not the same code 02:16:16 rudybot: eval (set! cons? pair?) 02:16:17 synx: error: eval:1:6: set!: cannot mutate module-required identifier in: cons? 02:16:28 rudybot: eval (define cons? pair?) 02:16:33 No such luck, Doc! 02:16:38 seemingly yes jcowan... 02:16:52 I meant the set! 02:17:06 Lilarcor [n=Lilarcor@pool-71-126-188-188.washdc.east.verizon.net] has joined #scheme 02:17:13 I'm curious if cons? and pair? are indeed different in plt, how they are different? 02:17:18 rudybot: eval (eq? cons? pair?) 02:17:18 synx: ; Value: #t 02:17:25 mwahaha 02:17:37 Anyhow, the plt documentation says they do the same thing 02:20:05 -!- xwl_ [n=user@147.243.236.60] has quit [Remote closed the connection] 02:27:56 -!- Lemonator [n=kniu@128.237.238.254] has quit [Read error: 110 (Connection timed out)] 02:35:43 kniu [n=kniu@CMU-284828.WV.CC.CMU.EDU] has joined #scheme 02:36:12 -!- SharkBrian [n=user@210.48.104.34] has quit [Read error: 110 (Connection timed out)] 02:43:44 hey synx i got my mobile working, now i have this to do this: http://pastebin.com/d10109de0 ; does this mean findnums must parse the list to single elements so i can use curry? 02:44:02 -!- Adamant [n=Adamant@unaffiliated/adamant] has quit [] 02:45:51 -!- metasyntax [n=taylor@pool-71-127-85-87.aubnin.fios.verizon.net] has quit [hubbard.freenode.net irc.freenode.net] 02:45:51 -!- leppie [n=lolcow@dsl-243-51-87.telkomadsl.co.za] has quit [hubbard.freenode.net irc.freenode.net] 02:45:51 -!- Kusanagi [n=Lernaean@unaffiliated/kusanagi] has quit [hubbard.freenode.net irc.freenode.net] 02:45:51 -!- foof [n=user@dn157-046.naist.jp] has quit [hubbard.freenode.net irc.freenode.net] 02:47:01 -!- tjafk2 [n=timj@e176210212.adsl.alicedsl.de] has quit [hubbard.freenode.net irc.freenode.net] 02:47:01 -!- Leonidas [n=Leonidas@unaffiliated/leonidas] has quit [hubbard.freenode.net irc.freenode.net] 02:47:01 -!- Qaexl [n=Akashakr@c-24-30-97-247.hsd1.ca.comcast.net] has quit [hubbard.freenode.net irc.freenode.net] 02:47:01 -!- laz0r [n=lazor@affenbande.org] has quit [hubbard.freenode.net irc.freenode.net] 02:47:01 -!- mmt [n=mmt@TEP.MIT.EDU] has quit [hubbard.freenode.net irc.freenode.net] 02:47:01 -!- lisppaste [n=lisppast@common-lisp.net] has quit [hubbard.freenode.net irc.freenode.net] 02:47:01 -!- kazzmir [n=kazzmir@c-98-202-86-149.hsd1.ut.comcast.net] has quit [hubbard.freenode.net irc.freenode.net] 02:49:42 -!- tverwaes [i=tverwaes@134.184.49.11] has quit [Remote closed the connection] 02:49:47 tverwaes [i=tverwaes@igwe11.vub.ac.be] has joined #scheme 02:51:25 -!- yosafbridge [n=yosafbri@ludios.net] has quit [Remote closed the connection] 02:52:46 yosafbridge [n=yosafbri@ludios.net] has joined #scheme 02:52:51 arcfide, it doesn't hurt my eyes so much, but it is still better without the stylesheet. 02:53:12 -!- tizoc [n=user@unaffiliated/tizoc] has quit [Remote closed the connection] 02:53:21 tizoc [n=user@unaffiliated/tizoc] has joined #scheme 02:54:03 metasyntax [n=taylor@pool-71-127-85-87.aubnin.fios.verizon.net] has joined #scheme 02:54:03 leppie [n=lolcow@dsl-243-51-87.telkomadsl.co.za] has joined #scheme 02:54:03 Kusanagi [n=Lernaean@unaffiliated/kusanagi] has joined #scheme 02:54:03 foof [n=user@dn157-046.naist.jp] has joined #scheme 02:54:08 tjafk2 [n=timj@e176210212.adsl.alicedsl.de] has joined #scheme 02:54:08 Leonidas [n=Leonidas@unaffiliated/leonidas] has joined #scheme 02:54:08 Qaexl [n=Akashakr@c-24-30-97-247.hsd1.ca.comcast.net] has joined #scheme 02:54:08 laz0r [n=lazor@affenbande.org] has joined #scheme 02:54:08 lisppaste [n=lisppast@common-lisp.net] has joined #scheme 02:54:08 kazzmir [n=kazzmir@c-98-202-86-149.hsd1.ut.comcast.net] has joined #scheme 02:54:08 mmt [n=mmt@TEP.MIT.EDU] has joined #scheme 02:54:09 Adamant [n=Adamant@c-76-29-188-22.hsd1.ga.comcast.net] has joined #scheme 02:56:00 I've never used curried functions, sorry. You probably want to look into the "fold" procedure though. 02:57:11 -!- synx [i=synx@gateway/gpg-tor/key-0xA71B0C6A] has quit [Remote closed the connection] 02:58:03 synx [i=synx@gateway/gpg-tor/key-0xA71B0C6A] has joined #scheme 03:12:42 melgray [n=melgray@pool-71-121-210-139.sttlwa.fios.verizon.net] has joined #scheme 03:13:16 -!- Adamant [n=Adamant@unaffiliated/adamant] has quit [] 03:15:49 sepult [n=buggarag@xdsl-87-78-29-70.netcologne.de] has joined #scheme 03:16:34 -!- Lilarcor [n=Lilarcor@pool-71-126-188-188.washdc.east.verizon.net] has quit [] 03:17:53 jonrafkind [n=jon@c-98-202-86-149.hsd1.ut.comcast.net] has joined #scheme 03:27:33 -!- kniu [n=kniu@CMU-284828.WV.CC.CMU.EDU] has quit [Remote closed the connection] 03:27:48 -!- bombshelter13_ [n=bombshel@209-161-233-254.dsl.look.ca] has quit [Client Quit] 03:41:04 -!- AtnNn [n=welcome@modemcable087.62-56-74.mc.videotron.ca] has quit [Read error: 104 (Connection reset by peer)] 03:42:15 AtnNn [n=welcome@modemcable087.62-56-74.mc.videotron.ca] has joined #scheme 03:42:55 Modius_ [n=Modius@adsl-69-150-57-149.dsl.austtx.swbell.net] has joined #scheme 03:45:01 excuse me but with "define-struct" how can i return a customized function? 03:45:03 jberg [n=johan@62.80-202-161.nextgentel.com] has joined #scheme 03:45:05 im so confused right now 03:45:57 -!- inforichland [n=inforich@96-42-29-58.dhcp.mdsn.wi.charter.com] has quit [] 03:46:18 -!- jcowan [n=jcowan@dsl-67-158-180-34.taconic.net] has left #scheme 03:46:29 -!- Adrinael [n=adrinael@barrel.rolli.org] has quit [hubbard.freenode.net irc.freenode.net] 03:46:29 -!- ray [i=ray@2001:41c8:1:54da:0:0:0:1337] has quit [hubbard.freenode.net irc.freenode.net] 03:46:29 -!- Modius [n=Modius@adsl-69-150-57-149.dsl.austtx.swbell.net] has quit [hubbard.freenode.net irc.freenode.net] 03:46:29 -!- synthase [n=synthase@68.63.19.212] has quit [hubbard.freenode.net irc.freenode.net] 03:47:10 saccade_ [n=saccade@65-78-24-47.c3-0.smr-ubr1.sbo-smr.ma.cable.rcn.com] has joined #scheme 03:47:22 Modius [n=Modius@adsl-69-150-57-149.dsl.austtx.swbell.net] has joined #scheme 03:47:22 synthase [n=synthase@68.63.19.212] has joined #scheme 03:47:22 Adrinael [n=adrinael@barrel.rolli.org] has joined #scheme 03:47:22 ray [i=ray@2001:41c8:1:54da:0:0:0:1337] has joined #scheme 03:48:17 append-map is the best thing ever 03:48:38 -!- Modius [n=Modius@adsl-69-150-57-149.dsl.austtx.swbell.net] has quit [Read error: 60 (Operation timed out)] 03:51:58 -!- sepult [n=buggarag@xdsl-87-78-29-70.netcologne.de] has quit ["leaving"] 03:52:51 -!- gweiqi [n=greg@69.120.126.163] has quit ["Leaving."] 03:52:51 sepult [n=buggarag@xdsl-87-78-29-70.netcologne.de] has joined #scheme 04:00:17 -!- geckosenator [n=sean@c-71-237-94-78.hsd1.co.comcast.net] has quit [Read error: 110 (Connection timed out)] 04:02:14 -!- MichaelRaskin [n=MichaelR@gwh-1-177-mytn23k1.ln.rinet.ru] has left #scheme 04:06:19 -!- sepult [n=buggarag@xdsl-87-78-29-70.netcologne.de] has quit ["Lost terminal"] 04:09:49 tjafk1 [n=timj@e176198206.adsl.alicedsl.de] has joined #scheme 04:13:18 instructions: http://pastebin.com/d50e260b3 ;;seems like i have to define-struct predicate? if so.. how can i return a customized function? all i know i can do with define-struct is use it as a data encapsulator 04:17:01 kniu [n=kniu@OVERLORD.RES.CMU.EDU] has joined #scheme 04:22:32 -!- pitui` [n=pitui@c-76-98-192-104.hsd1.nj.comcast.net] has quit [Read error: 110 (Connection timed out)] 04:27:11 -!- tjafk2 [n=timj@e176210212.adsl.alicedsl.de] has quit [Read error: 110 (Connection timed out)] 04:27:26 any active users here? 04:31:30 kinda 04:31:48 but I don't know much about define-struct, I'm a newb as well 04:35:46 :( 04:36:14 how come when i have a statement like 04:36:33 (eq? e (quote <)) #t) 04:36:38 it returns false 04:36:48 even when e is '< 04:36:58 do i need to use equal? 04:37:56 JasonPhD, i know your in my PLC class. 04:38:07 >_> 04:38:25 wow 04:38:34 nice 04:38:39 funny right? 04:38:52 how far are you? 04:39:22 (let ((e '<)) (eq? e (quote <))) returns #t for me 04:39:24 im stuck at part2 04:39:31 mhmm 04:39:42 (findnums) -totally lost 04:39:43 i see sohum.. 04:39:54 do you have the little schemer book that was optional? 04:40:02 no :( 04:40:05 it really has helped me with the concept of currying 04:40:06 oh 04:40:19 i think i got the basic of currying just that.. 04:40:22 well a hint would be to use nested lambda expressions 04:40:28 http://pastebin.com/d50e260b3 what does this mean? 04:40:51 seems like i have define-struct predicate... and make it return a function? 04:40:55 this is exactly what i'm working on 04:41:05 you don't want to use structs for this 04:41:58 sohum, what if you don't quote the < symbol 04:42:06 how can you still test for it? 04:45:38 It sounds like you're making the problem too hard. 04:45:43 that's what i thnk 04:45:44 think* 04:45:55 after re-reading the writeup i have a better approach 04:46:03 make-predicate takes a procedure, and the first argument to the procedure. 04:46:23 It returns a new procedure, that applies the first argument, and then other arguments, to that original procedure. 04:46:39 I don't know why they call it currying though. I'd just call it a closure. 04:46:44 mhmm 04:47:23 so worrying over whether it's the symbol '< isn't a good idea. Just write make-predicate to take any procedure as its first argument, and pass <. 04:47:55 andrewSC: you mean, you want to pass the < function? 04:48:16 yes 04:48:36 (let ((e <)) (eq? e <)) works as well 04:48:45 mhmm 04:48:45 though that blows my mind a tad 04:48:48 haha 04:49:42 -!- arcfide [n=arcfide@adsl-99-50-230-39.dsl.bltnin.sbcglobal.net] has quit ["Leaving"] 04:58:35 NICE 04:58:36 :) 05:00:18 -!- teiresias [n=user@ip68-12-115-220.ok.ok.cox.net] has quit ["ERC Version 5.2 (IRC client for Emacs)"] 05:01:28 -!- kniu [n=kniu@OVERLORD.RES.CMU.EDU] has quit [Read error: 110 (Connection timed out)] 05:01:49 kniu [n=kniu@128.237.247.188] has joined #scheme 05:05:48 intresting 05:05:53 im still at lost :< 05:06:27 i've run into a small problem 05:06:46 i can get make-predicate to work with the < 5 05:06:49 however 05:07:03 i'm not sure how they expect that same function to work with say 05:07:05 zero? 05:07:19 seeing as zero? just takes one arg and < takes two 05:07:58 true. but we have to pass in a list right? 05:09:16 la la la 05:09:17 andrewSC: so how do you run your make-predicate? do you (make-predicate < 3 ) 2) ? 05:09:17 yeah but that can be taken apart by find nums 05:09:24 homework? 05:09:30 lab :] 05:09:46 well, i use the guideline 05:09:49 so 05:10:04 (define test (make-predicate < 5)) 05:10:05 then 05:10:09 (test 4) 05:10:14 will return false 05:10:17 hmmmm 05:10:25 that's it for and (test 6) will produce true 05:10:38 yep 05:10:48 i mean obviously the function is a little bit more complex 05:10:56 but calling it is rather simple 05:13:26 so we never use findnums and make-predicate together? (findnums test '(2)) ? 05:14:19 no no, findnums uses make-predicate 05:14:36 oh i see what your trying to say 05:14:38 hmm 05:14:41 let me take a look 05:14:55 yes 05:15:07 you pass the predicate function to findnums 05:15:15 so you would have defined it eariler like you suggested 05:15:40 wouldn't you just return a closure? 05:16:54 something like (define (make-predicate fn arg1) (lambda ( .. wait, does scheme have &rest? 05:17:06 sohum: YES 05:17:20 synx: AH 05:17:38 does findnums have to somehow pull apart the "predicate" that you're passing to it? Or does it just call that predicate as a procedure. 05:18:16 call that predicate as a procedure 05:18:24 synx, PM? 05:18:32 (define (findnums predicate ...) (predicate-procedure predicate) (predicate-first-argument predicate) ...) is far different from just (define (findnums predicate ...) ((predicate) something)) 05:18:39 synx: full description does it just call that predicate as a procedure. 05:18:41 whoops 05:18:42 please no andrewSC 05:18:45 ok 05:18:54 synx: full description : http://pastebin.com/d7f743cdf 05:19:49 It doesn't look like you need currying then, just closures. 05:19:54 so far i can get true with: > (findnums (make-predicate > 10) '(9)) 05:20:36 sohum: the "rest" argument in scheme is expressed as dotted list notation in the arguments for a procedure. (define (foo a b c . rest) ...) f/i or (define foo (lambda (a b c . rest) ...)) 05:20:54 ah, ok 05:21:16 paste an example of your code JasonPhD and maybe people can identify what's not right about it. Make sure you think carefully about what you're doing though. 05:21:39 so far i got this http://pastebin.com/d2c29e139 05:22:04 sohum: it's keyword arguments that don't have a widely accepted standard... 05:22:22 so something like (define (curry fn arg1) (lambda ( . rest) (apply fn (cons arg1 rest)))) is how I'd do it. If ( . rest) works 05:23:03 JasonPhD: Are you sure it should be (op num num2)? Because (make-predicate < 5) makes me think "less-than-5" not "5-is-less-than" which is what you did. Maybe need to switch those. 05:23:42 I don't think currying is just closures. I think it's some kind of special notation or something...maybe... don't really know. 05:23:54 so (op num2 num); ok! ; but is what im doing is what they want? 05:24:35 -!- cracki [n=cracki@sglty.kawo2.RWTH-Aachen.DE] has quit [Read error: 113 (No route to host)] 05:25:32 *but is my current code is what they requestor im doing something else? 05:25:34 because i see 05:26:03 currying /is/ just closures, I'm pretty sure. Do they want you to drop a notation on top of it? 05:26:03 i have to pull off this (findnums zero? '(1 2 3)) ; returns an empty list since there's no zero 05:27:06 i am so close to getting this 05:27:15 i've created a generic make-predicate 05:27:28 -!- aardvarq [i=tgAardva@student3113.student.nau.edu] has quit [Read error: 110 (Connection timed out)] 05:27:29 it's just the recursion 05:27:34 in findnums that's tripping me up 05:30:46 It's not my assignment sohum. I don't know much about currying. 05:32:06 fair enough, synx. but yea, I'm pretty sure that's all currying is. 05:32:41 i think so too.. i remember the professor say currying ~= closure 05:32:54 lol i don't remember that.. 05:32:56 It seems to be the case now that I look at it, yes. 05:32:59 something like... 05:33:15 i do remember alot of the kids having trouble understanding the make-predicate part though.. 05:33:16 "with currying.. the variable .... and closure" 05:33:18 The only thing plt provides is a "curry" function which is a shortcut for what we've already been doing here with closures. 05:33:25 mhmm 05:33:34 pretty sure he just means closure 05:33:40 procedures that generate procedures are pretty difficult to grok at first. 05:33:48 I still struggle with syntax generating syntaxes myself. 05:33:54 :] 05:33:56 metamacros! 05:33:56 funnnnn 05:34:09 i love code 05:34:29 phase 1 can repeat several times T_T 05:34:33 but does it love me back? 05:34:45 :) 05:36:05 also JasonPhD, i'm pretty sure we lose points by using apply 05:36:12 i'm not 100% sure though.. 05:36:41 apply is pretty much necessary if you're appending argument lists together. 05:37:01 i remember the dude in the front say.. "just use apply" then some other student said "can we use it? 05:37:05 professor didnt respond 05:37:09 You could write a "curry" function that used apply, then never use apply yourself... 05:37:20 yeah Joe is in a different world though... 05:37:21 synx: cant we use a recursion car? 05:37:27 apply won't work for currying by itself... 05:37:33 Hmm JasonPhD... 05:37:45 that's what i'm trying to write 05:37:51 something like... 05:37:53 the catch is the whole sublists thing 05:38:01 you car a list with a sublist 05:38:08 you get that sublist 05:38:10 :( 05:38:15 not just a number 05:38:20 i honestly dont wanna go that far :( 05:38:24 lmao 05:38:36 your grade man 05:38:36 recurse on the arguments until they're exhausted, returning a new curry each time, until they're exhausted the last curry calls the function. 05:38:57 mhmm 05:39:10 using rember? 05:39:15 It'd still have to use apply though... 05:39:53 Maybe not if you used call-with-values...hmph 05:40:15 Okay I gotta try to implement curry now without apply hehe 05:40:52 I'm not sure that's possible, without extra work that doesn't make anything clearer 05:41:41 : \ 05:41:55 Also JasonPhD, i was going to contact Joe but hes afk according to aim 05:42:10 o u know him? 05:42:16 i sit next to him 05:42:17 on the left 05:42:24 i dont know anyone in my class.. and my partner withdraw :( 05:42:29 shitttyyy man 05:42:36 that project is going to own your lifeee 05:42:39 lol 05:42:44 your the top row 05:42:45 ? 05:42:47 yeah 05:42:51 front row 05:42:54 left side 05:43:23 there three tables.. left middle right.. joe is in the middle table of the left, right? 05:43:38 the left of the middle table*? 05:43:54 Joe sits in the front row left side of the middle table 05:44:00 right. 05:44:07 xwl_ [n=user@147.243.236.60] has joined #scheme 05:44:10 i sit at the left table in the front on the right side 05:44:17 *as mean correct 05:44:17 so aisle seat 05:44:18 ok i see 05:44:33 im easy to spot.. im the only asian guy 05:44:36 haha 05:44:45 the russians look fairly asian so idk.. 05:44:53 there kakhastan 05:44:56 ahh ok 05:45:06 actually i know one of them.. but he's not online 05:45:32 mhmm 05:47:18 ahh shit.. the more i attempt to code findnums the worst it gets 05:47:33 meh 05:47:41 i'm kinda poking here and there on it 05:47:49 remember 05:47:50 write the code 05:47:54 then simplify 05:48:10 make it run.. then make it run faster - steele 05:49:09 you got it 05:50:24 -!- dysinger [n=tim@cpe-75-80-200-182.hawaii.res.rr.com] has quit [] 05:51:55 i'm having some trouble with pred wanting to evaluate when it shouldn't 05:52:15 nah I can't do it. what I thought would work just discards all the arguments. 05:53:04 : \ 05:53:14 worth a shot though right :) 05:53:32 synx, so you think we need to use apply? 05:55:22 uh...yes 05:55:24 "yes" 05:55:32 ;) 05:55:33 haha 05:55:36 .. quotes... 05:55:37 You can't /just/ use apply though. 05:55:43 mhmm 05:55:49 I plead the 5th 05:56:20 fair enough 05:56:23 :) 05:58:29 i'm not very familiar with apply... 05:59:21 http://www.schemers.org/Documents/Standards/R5RS/HTML/r5rs-Z-H-9.html#%_idx_556 05:59:23 -rudybot:#scheme- http://tinyurl.com/2kjgxd 05:59:52 thanks JasonPhD 06:00:01 Adamant [n=Adamant@c-76-29-188-22.hsd1.ga.comcast.net] has joined #scheme 06:01:01 still i dont know how will i use apply such that i can get (findnums zero? '(1 0 91 0)) to produce the list (0 0). 06:02:17 You don't need to use apply for that. You need apply for make-predicate 06:03:40 synx: for what? 06:03:48 indeed 06:03:49 for what predicate? 06:03:57 for make-predicate 06:03:58 how would apply work for make-predicate 06:04:04 i mean what type.. < > etc 06:04:06 It's a procedure in your assignment. 06:04:27 andrewSC: once you have a list of the arguments, you apply them to the procedure you're currying. 06:04:42 Doesn't matter JasonPhD 06:04:42 mhmm 06:05:46 this is an interesting idea.. Why couldn't i just use nested lambda functions? 06:07:03 synx: if that's true.. does findnum's parse the first element in the list and pass the rest of the list to make-predicate? 06:07:32 that doesn't seem to make sense JasonPhD.. i think it's the other way around 06:07:36 (aPredicate firstelement restof-thelist) 06:07:38 hmm 06:07:48 like make-predicate only takes the car of the given list 06:07:51 ie: 5 06:08:02 it returns a #t or #f 06:09:20 so findnums would just continually car the values off a list assuming there are no sublists and whatever the return of make-predicate is determines weather or not to take that value and cons it onto a new list 06:09:34 JasonPhD: findnum doesn't do anything with make-predicate. make-predicate just makes things for findnum to use. 06:09:36 that's what i'm trying to do right now 06:09:42 exactly 06:10:03 i might just call it. 06:10:14 this is way to tense for the 20 points it's worth 06:10:35 this lab should be worth 50 for the trouble it's caused me the past couple of days... 06:10:51 yea definitely 06:11:39 i want some bacon 06:11:47 brb afk 06:11:52 -!- xwl_ [n=user@147.243.236.60] has quit [Remote closed the connection] 06:13:25 dogs won't believe it's not 06:13:30 synx: ok..... so to get (findnums zero? '(1 0 91 0)) to produce the list (0 0). ; this mean findnum will use make-predicate to retrieve t/f. if t then append a list. so findnum have to some how loop make-predicate.. ? 06:14:00 No, findnums will not use make-predicate at all. It will only use zero? 06:14:13 o :( 06:14:31 sebell [n=sctb@S01060016cbc2d41a.cg.shawcable.net] has joined #scheme 06:14:44 so < will be defintiely use by make-predicat 06:14:44 It needs to filter the list. If the predicate is false for an element, then filter out that element. 06:15:21 What they mean by "predicate" is: "A procedure that will take 1 argument and return true or false." 06:15:25 ...is my guess. 06:15:30 back 06:15:31 yep 06:15:56 < takes two arguments though. (< 0) is too few arguments. 06:16:09 i just defined the make-predicate then used that identifier for the findnums procedure 06:16:16 right 06:16:19 You need to make a new procedure that uses <, but only takes 1 argument. 06:17:19 (lambda (a) (lambda (b) (< a b))) is a predicate. < by itself is not. 06:18:21 rudybot: eval (define foo (lambda (a) (lambda (b) (display "Two args ~a ~a" a b)))) 06:18:30 rudybot: eval (foo 23) 06:18:31 synx: ; Value: # 06:18:41 rudybot: eval ((foo 23) 42) 06:18:42 synx: error: display: expects 1 to 2 arguments, given 3: "Two args ~a ~a" 23 42 06:18:56 arg 06:19:01 humbug 06:19:03 rudybot: eval (define foo (lambda (a) (lambda (b) (display (format "Two args ~a ~a" a b))))) 06:19:08 I always forget (format) 06:19:12 rudybot: eval ((foo 23) 42) 06:19:13 lol 06:19:13 synx: ; stdout: "Two args 23 42" 06:19:32 rudybot: eval (define a-predicate (foo 23)) 06:19:44 mmc [n=mima@esprx02x.nokia.com] has joined #scheme 06:19:55 rudybot: eval (a-predicate 42) (a-predicate 19) (a-predicate 82) 06:19:56 synx: ; stdout: "Two args 23 42Two args 23 19Two args 23 82" 06:20:39 That's what it means when a procedure creates and returns a procedure. 06:26:18 -!- andrewSC [n=andrew@ipanema.parkpointrit.com] has quit [Remote closed the connection] 06:28:21 -!- rudybot [n=luser@q-static-138-125.avvanta.com] has quit [hubbard.freenode.net irc.freenode.net] 06:28:21 -!- underspecified [n=eric-n@leopard175.naist.jp] has quit [hubbard.freenode.net irc.freenode.net] 06:28:21 -!- tarbo [n=me@unaffiliated/tarbo] has quit [hubbard.freenode.net irc.freenode.net] 06:28:21 -!- Arelius [n=indy@64.174.9.113] has quit [hubbard.freenode.net irc.freenode.net] 06:28:21 -!- zbigniew [n=zb@3e8.org] has quit [hubbard.freenode.net irc.freenode.net] 06:28:21 -!- kspaans [i=kspaans@artificial-flavours.csclub.uwaterloo.ca] has quit [hubbard.freenode.net irc.freenode.net] 06:28:21 -!- r0bby [n=wakawaka@guifications/user/r0bby] has quit [hubbard.freenode.net irc.freenode.net] 06:28:32 tarbo [n=me@unaffiliated/tarbo] has joined #scheme 06:28:34 rudybot [n=luser@q-static-138-125.avvanta.com] has joined #scheme 06:28:34 underspecified [n=eric-n@leopard175.naist.jp] has joined #scheme 06:28:34 r0bby [n=wakawaka@guifications/user/r0bby] has joined #scheme 06:28:34 Arelius [n=indy@64.174.9.113] has joined #scheme 06:28:34 kspaans [i=kspaans@artificial-flavours.csclub.uwaterloo.ca] has joined #scheme 06:28:34 zbigniew [n=zb@3e8.org] has joined #scheme 06:29:27 lowlycoder [n=x@unaffiliated/lowlycoder] has joined #scheme 06:30:06 -!- kniu [n=kniu@128.237.247.188] has quit [Read error: 110 (Connection timed out)] 06:30:36 kniu [n=kniu@OVERLORD.RES.CMU.EDU] has joined #scheme 06:37:21 -!- Kusanagi [n=Lernaean@unaffiliated/kusanagi] has quit [Read error: 110 (Connection timed out)] 06:38:57 > (cons '() '()) 06:38:57 ; returns (list empty) ... how can i make it return () 06:39:44 -!- sebell [n=sctb@S01060016cbc2d41a.cg.shawcable.net] has quit ["rcirc on GNU Emacs 22.1.1"] 06:42:11 -!- lowlycoder [n=x@unaffiliated/lowlycoder] has left #scheme 06:45:51 -!- hadronzoo [n=hadronzo@user-0c2h0f1.cable.mindspring.com] has quit [] 06:51:50 npe [n=npe@195.207.5.2] has joined #scheme 06:52:49 mmmulani_ [n=mmmulani@nat/uwaterloo/x-90da99214be43dee] has joined #scheme 06:54:12 JasonPhD: and (list ) ? 06:54:49 -!- amoe [n=amoe@cpc1-brig3-0-0-cust512.brig.cable.ntl.com] has left #scheme 06:59:00 Kusanagi [n=Lernaean@68-184-239-20.dhcp.stls.mo.charter.com] has joined #scheme 06:59:58 xwl_ [n=user@147.243.236.60] has joined #scheme 07:00:28 Ragnaroek [i=54a66c54@gateway/web/ajax/mibbit.com/x-0f3f4a2a34d6cd03] has joined #scheme 07:04:02 mmc:? 07:04:37 JasonPhD: I think you cannot create an empty list with cons 07:05:10 o.. 07:05:14 JasonPhD: but (list ) does. 07:05:16 -!- Kusanagi [n=Lernaean@unaffiliated/kusanagi] has quit [Client Quit] 07:05:53 sepult [n=buggarag@xdsl-87-78-29-70.netcologne.de] has joined #scheme 07:06:22 -!- melgray [n=melgray@pool-71-121-210-139.sttlwa.fios.verizon.net] has quit [] 07:07:11 -!- mmmulani [n=mmmulani@nat/uwaterloo/x-22105490177c20ed] has quit [Read error: 104 (Connection reset by peer)] 07:07:12 -!- sanguine1 is now known as sanguinev 07:07:16 Kusanagi [n=Lernaean@unaffiliated/kusanagi] has joined #scheme 07:07:58 melgray [n=melgray@pool-71-121-210-139.sttlwa.fios.verizon.net] has joined #scheme 07:10:59 ASau` [n=user@host197-231-msk.microtest.ru] has joined #scheme 07:15:28 -!- Kusanagi [n=Lernaean@unaffiliated/kusanagi] has quit [] 07:17:01 Kusanagi [n=Lernaean@68-184-239-20.dhcp.stls.mo.charter.com] has joined #scheme 07:17:56 what's the equivalent of "else if" 07:18:35 specbot: R5RS cond 07:18:36 http://www.schemers.org/Documents/Standards/R5RS/HTML/r5rs-Z-H-7.html#%_idx_106 07:18:38 -rudybot:#scheme- http://tinyurl.com/3gogwm 07:27:38 MrFahrenheit [n=RageOfTh@92.36.220.53] has joined #scheme 07:32:33 -!- leppie [n=lolcow@dsl-243-51-87.telkomadsl.co.za] has quit [Remote closed the connection] 07:32:47 how does scheme operate with top-level lets? 07:33:44 leppie [n=lolcow@dsl-243-51-87.telkomadsl.co.za] has joined #scheme 07:36:42 mike [n=m@dslb-088-066-233-027.pools.arcor-ip.net] has joined #scheme 07:37:10 -!- mike is now known as Guest98948 07:40:22 sohum_ [n=sohum@122.110.5.28] has joined #scheme 07:40:43 -!- sohum [n=sohum@unaffiliated/sohum] has quit [Nick collision from services.] 07:41:06 -!- sohum_ is now known as sohum 07:44:22 ecraven [n=nex@140.78.42.103] has joined #scheme 07:50:16 based on docs.plt-scheme.org : (cons 0 (cons 1 (cons 2 null))); should return 07:50:16 (0 1 2) 07:50:26 is there a way to make (define (foo args) ... (or (foo args') (foo args''))) tail-recursive? 07:50:32 if i paste this ... it will give me (list 0 1 2).... how do i remove it? 07:50:42 remove the "list" 07:51:53 -!- leppie [n=lolcow@dsl-243-51-87.telkomadsl.co.za] has quit [Read error: 60 (Operation timed out)] 07:52:24 rudybot: eval (cons 0 (cons 1 (cons 2 null))) 07:52:25 ecraven: your sandbox is ready 07:52:25 ecraven: ; Value: (0 1 2) 07:52:39 joast [n=rick@76.178.184.231] has joined #scheme 07:55:16 -!- CaptainMorgan [n=CaptainM@c-75-68-42-94.hsd1.nh.comcast.net] has quit [Remote closed the connection] 07:55:25 leppie [n=lolcow@dsl-243-51-87.telkomadsl.co.za] has joined #scheme 08:15:48 -!- JasonPhD [n=Jason@ipanema.parkpointrit.com] has quit ["Leaving"] 08:19:36 ct2rips [n=ct2rips@blfd-4db1d89b.pool.einsundeins.de] has joined #scheme 08:32:05 -!- melgray [n=melgray@pool-71-121-210-139.sttlwa.fios.verizon.net] has quit [] 08:38:10 thehcdreamer [n=thehcdre@94.198.78.26] has joined #scheme 08:39:18 -!- MrFahrenheit [n=RageOfTh@92.36.220.53] has quit [Read error: 110 (Connection timed out)] 08:40:05 -!- leppie [n=lolcow@dsl-243-51-87.telkomadsl.co.za] has quit [Remote closed the connection] 08:43:53 Nshag [i=user@Mix-Orleans-106-2-129.w193-248.abo.wanadoo.fr] has joined #scheme 08:45:31 -!- kniu [n=kniu@OVERLORD.RES.CMU.EDU] has quit [Read error: 110 (Connection timed out)] 08:46:18 kniu [n=kniu@CMU-284828.WV.CC.CMU.EDU] has joined #scheme 08:55:19 jlongster [n=user@c-68-59-187-95.hsd1.tn.comcast.net] has joined #scheme 08:57:30 darth_chatri [n=darth@202.71.143.214] has joined #scheme 08:57:43 cracki [n=cracki@45-221.eduroam.RWTH-Aachen.DE] has joined #scheme 08:59:50 hi, i'm a newbie starting with SICP and using drscheme. I tried some local defines, but they do not work. (http://pastebin.com/m3ed87bd5) 09:00:10 can someone tell me what I am doing wrong here? 09:03:49 did you set drscheme to the right language level? 09:04:36 -!- thehcdreamer [n=thehcdre@94.198.78.26] has quit [] 09:05:44 ecraven, what would that be? 09:05:56 i've set it to advanced student 09:06:26 i have no idea, but i know that some of the lesser levels don't allow full scheme.. does it have anything that says r5rs? 09:07:19 heh. this thing seem to be 'user-friendly'. it has stuff like 'module' or 'beginning student' ... 09:07:35 i'll go through the docs and look for r5rs 09:11:37 it worked when i chose r5rs. i had ignored it earlier since it was part of 'legacy languages' 09:24:34 leppie [n=lolcow@dsl-243-51-87.telkomadsl.co.za] has joined #scheme 09:25:00 orgy` [n=ratm_@pD9FFE584.dip.t-dialin.net] has joined #scheme 09:34:53 Mr-Cat [n=Miranda@hermes.lanit.ru] has joined #scheme 09:37:51 -!- Ragnaroek [i=54a66c54@gateway/web/ajax/mibbit.com/x-0f3f4a2a34d6cd03] has quit ["http://www.mibbit.com ajax IRC Client"] 09:38:50 Ragnaroek [i=54a66c54@gateway/web/ajax/mibbit.com/x-0e7cb993f1e7746c] has joined #scheme 09:39:07 -!- saccade_ [n=saccade@65-78-24-47.c3-0.smr-ubr1.sbo-smr.ma.cable.rcn.com] has quit ["This computer has gone to sleep"] 09:44:26 geckosenator [n=sean@c-71-237-94-78.hsd1.co.comcast.net] has joined #scheme 09:47:09 -!- sepult [n=buggarag@xdsl-87-78-29-70.netcologne.de] has quit ["Lost terminal"] 09:47:49 Elone [n=elone@c-71-202-143-119.hsd1.ca.comcast.net] has joined #scheme 09:50:41 hello 09:51:04 darth_chatri: there's probably something better, but i don't know enough about drscheme.. ask around, some people here work on drscheme 09:58:55 question: ~ suppose i have a string "abc" in runtime , can i have a code make use the string in define so (define "abc" 123)? 10:01:55 you can use a macro for that 10:02:43 marco? 10:03:02 What is the problem you want to solve? 10:05:27 I am to warting a simple spreadsheet program that read tabbed text file. 10:06:03 and in the cell i need to have like (A1 + 3) 10:06:36 so i wanna make "A1" define dynamicaly in runtime 10:06:54 use a hash table? 10:08:26 i don't know ~ i am new to scheme 10:15:47 -!- jlongster [n=user@c-68-59-187-95.hsd1.tn.comcast.net] has quit [Read error: 113 (No route to host)] 10:16:36 -!- jld [i=jld@kurobara.xlerb.net] has quit [Success] 10:19:46 I'd suggest a hash table, what Scheme are you using? 10:22:01 puchacz [n=puchacz@87-194-5-99.bethere.co.uk] has joined #scheme 10:28:51 I need a scheme that can read my mind directly 10:29:36 :-) 10:30:24 Elonetaru [n=elone@c-71-202-143-119.hsd1.ca.comcast.net] has joined #scheme 10:34:14 jewel_ [n=jewel@dsl-247-205-254.telkomadsl.co.za] has joined #scheme 10:40:12 Judofyr [n=Judofyr@95.34.25.154.customer.cdi.no] has joined #scheme 10:42:42 elias` [n=me@cs78208074.pp.htv.fi] has joined #scheme 10:42:43 -!- Elone [n=elone@c-71-202-143-119.hsd1.ca.comcast.net] has quit [Read error: 110 (Connection timed out)] 10:43:08 -!- jewel_ [n=jewel@dsl-247-205-254.telkomadsl.co.za] has quit [Read error: 60 (Operation timed out)] 11:23:27 -!- ASau [n=user@193.138.70.52] has quit [Remote closed the connection] 11:23:43 ASau [n=user@193.138.70.52] has joined #scheme 11:26:14 -!- Judofyr [n=Judofyr@95.34.25.154.customer.cdi.no] has quit [Remote closed the connection] 11:30:22 -!- Deformative [n=joe@71.238.45.45] has quit [Read error: 104 (Connection reset by peer)] 11:30:42 -!- Deformati [n=joe@71.238.45.45] has quit [Remote closed the connection] 11:30:42 -!- Def [n=joe@71.238.45.45] has quit [Remote closed the connection] 11:30:44 is there a static let in scheme like c++ in a function? 11:31:01 so i can i have a static varible in a funtion? 11:31:43 -!- ASau [n=user@193.138.70.52] has quit [Remote closed the connection] 11:31:49 ASau [n=user@193.138.70.52] has joined #scheme 11:35:37 What exactly do you need? A global variable? 11:35:53 There are no static functions in Scheme by default 11:52:09 jberg_ [n=johan@62.80-202-161.nextgentel.com] has joined #scheme 11:52:42 xwl [n=user@222.35.124.5] has joined #scheme 11:57:28 -!- jberg [n=johan@62.80-202-161.nextgentel.com] has quit [Read error: 113 (No route to host)] 12:01:59 Elonetaru: Do you know what a closure is? 12:05:43 -!- Modius_ [n=Modius@adsl-69-150-57-149.dsl.austtx.swbell.net] has quit [Read error: 104 (Connection reset by peer)] 12:10:24 jewel_ [n=jewel@dsl-247-205-254.telkomadsl.co.za] has joined #scheme 12:13:38 mejja [n=user@c-f6b6e555.023-82-73746f38.cust.bredbandsbolaget.se] has joined #scheme 12:14:37 Modius_ [n=Modius@adsl-69-150-57-149.dsl.austtx.swbell.net] has joined #scheme 12:15:54 Edico [n=Edico@unaffiliated/edico] has joined #scheme 12:16:56 Elonetaru: C++-like static variables seems to be not a scheme way 12:18:10 I wish Scheme did macro expansion like cl 12:18:42 unhygienic? 12:18:50 Elonetaru: But you may have coroutines, it is much more fun :) 12:19:07 Quadrescence: Why? 12:19:48 jld [i=jld@kurobara.xlerb.net] has joined #scheme 12:20:07 Mr-Cat: Maybe it's a result of my ignorance, but, CL macros just seem more natural; that is, the syntax is similar to that of a function definition. I don't know. 12:20:24 I am by no means an experienced Schemer though. 12:23:39 there are Scheme macro systems that transform S-expressions with a procedure just like CL, but hygienic 12:24:04 for example explicit renaming, syntactic closures and SRFI 72 12:24:25 Quadrescence: Scheme macros is something, one spends some time to get accustomed to. Still, you may have cl-like macros by using syntax->datum and datum->syntax. 12:24:48 some implementations also provide non-hygienic procedural macros, but they aren't very popular 12:27:49 Maybe I should just inform myself on scheme macros more before complaining. :) 12:28:34 -!- xwl [n=user@222.35.124.5] has quit [Remote closed the connection] 12:29:28 xwl [n=user@222.35.124.5] has joined #scheme 12:30:13 er and sc can be used non-hygienically 12:31:28 (cyclic? x) => #t iff x contains any cycles (not just shared structure) 12:31:59 This is O(nd) time where n is the size of x and d the maximum path depth, O(d) space, right? 12:33:16 Is there a hare-tortoise algorithm for O(1) space? 12:34:24 For arbitrary graphs you can use Strongly Connected Component finders like Tarjan's algorithm 12:34:53 O(n) time and O(d) space I think 12:36:15 Thanks, I'll check that. 12:36:42 If you find any SCC with more than 1 node you have a cycle 12:38:15 actually O(n+d) space probably, because you need some metadata for each node 12:39:02 -!- sohum [n=sohum@unaffiliated/sohum] has quit [Read error: 60 (Operation timed out)] 12:43:04 Hmmm... that algorithm assumes we can manipulate satellite data on objects in O(1) time. 12:44:47 -!- jewel_ [n=jewel@dsl-247-205-254.telkomadsl.co.za] has quit [Connection timed out] 12:57:58 -!- cracki [n=cracki@45-221.eduroam.RWTH-Aachen.DE] has quit ["The funniest things in my life are truth and absurdity."] 12:58:33 -!- Mr-Cat [n=Miranda@hermes.lanit.ru] has quit [Read error: 104 (Connection reset by peer)] 13:09:27 jewel_ [n=jewel@dsl-247-205-254.telkomadsl.co.za] has joined #scheme 13:18:20 alaricsp [n=alaricsp@217.205.201.45] has joined #scheme 13:23:38 -!- leppie [n=lolcow@dsl-243-51-87.telkomadsl.co.za] has quit [Remote closed the connection] 13:25:46 leppie [n=lolcow@dsl-243-51-87.telkomadsl.co.za] has joined #scheme 13:30:06 cracki [n=cracki@sglty.kawo2.RWTH-Aachen.DE] has joined #scheme 13:33:33 -!- xwl [n=user@222.35.124.5] has quit [Remote closed the connection] 13:37:31 ejs [n=eugen@nat.ironport.com] has joined #scheme 13:38:36 -!- leppie [n=lolcow@dsl-243-51-87.telkomadsl.co.za] has quit [Read error: 54 (Connection reset by peer)] 13:39:42 leppie [n=lolcow@dsl-243-51-87.telkomadsl.co.za] has joined #scheme 13:56:40 MrFahrenheit [n=RageOfTh@92.36.156.248] has joined #scheme 13:58:39 Is there a commonly used emacs mode for scheme? 14:00:26 scheme-mode 14:00:51 Mr-Cat [n=Miranda@hermes.lanit.ru] has joined #scheme 14:06:23 teiresias [n=user@ip68-12-115-220.ok.ok.cox.net] has joined #scheme 14:10:24 Quadrescence: just use drscheme. 14:10:45 drscheme isn't an emacs mode 14:11:27 emma: I mostly like drscheme, but I, personally, find a lot of things I don't like. I would hack at it to make it the way I want it, but that's a lot of work. :/ 14:12:39 I started up emacs for the first time to try to learn common lisp with slime. 14:12:44 I guess it's good. 14:12:54 I find slime fine. But emacs a little awkward. 14:14:09 Can slime be (easily) used with scheme? 14:16:25 It's really not that hard to hack drscheme. It's just a scheme program after all. 14:16:32 You have to deal with PLT's custom GUI though. 14:18:32 Quadrescence: nope 14:19:01 -!- sad0ur [n=sad0ur@psi.cz] has quit [Remote closed the connection] 14:19:12 sad0ur [n=sad0ur@psi.cz] has joined #scheme 14:19:20 synx: It's mostly the custom GUI and whatever. I looked at the source code; I am just not motivated to learn it. 14:19:44 rodge: So is scheme-mode the only [sane] way to go here? 14:20:01 just about 14:20:25 there are some implementation specific modes as well 14:20:32 but nothing as powerful as slime 14:21:55 rodge: Does scheme-mode at lease have something like C-c C-k or C-c C-c? :< 14:22:15 xwl [n=user@114.246.89.53] has joined #scheme 14:22:50 yes, you can send code to a repl and such 14:26:32 emacs has a custom GUI too if you can call it a GUI :p 14:26:43 more people familiar with emacs though 14:30:48 -!- leppie [n=lolcow@dsl-243-51-87.telkomadsl.co.za] has quit [Read error: 60 (Operation timed out)] 14:31:27 leppie [n=lolcow@dsl-243-51-87.telkomadsl.co.za] has joined #scheme 14:31:58 -!- darth_chatri [n=darth@202.71.143.214] has quit ["Leaving"] 14:34:14 -!- elias` [n=me@unaffiliated/elias/x-342423] has quit [Read error: 131 (Connection reset by peer)] 14:38:38 I love the paren highlighting in drscheme. I want that in emacs. :< 14:44:35 reprore [n=reprore@ntkngw261071.kngw.nt.ftth.ppp.infoweb.ne.jp] has joined #scheme 14:45:18 -!- sad0ur [n=sad0ur@psi.cz] has quit [Remote closed the connection] 14:45:29 sad0ur [n=sad0ur@psi.cz] has joined #scheme 15:04:19 glogic_ [n=glogic@5ess.net] has joined #scheme 15:09:02 -!- synthase [n=synthase@68.63.19.212] has quit [Read error: 60 (Operation timed out)] 15:10:33 -!- ecraven [n=nex@140.78.42.103] has quit ["bbl"] 15:12:00 -!- mmmulani_ is now known as mmmulani 15:18:00 -!- glogic [n=glogic@5ess.net] has quit [Read error: 110 (Connection timed out)] 15:24:14 Fare [n=Fare@ita4fw1.itasoftware.com] has joined #scheme 15:29:39 -!- kniu [n=kniu@CMU-284828.WV.CC.CMU.EDU] has quit [Read error: 60 (Operation timed out)] 15:34:46 -!- Guest98948 [n=m@dslb-088-066-233-027.pools.arcor-ip.net] has quit ["This computer has gone to sleep"] 15:41:32 elias` [n=me@cs78208074.pp.htv.fi] has joined #scheme 15:48:46 -!- jonrafkind [n=jon@c-98-202-86-149.hsd1.ut.comcast.net] has quit [Connection timed out] 15:49:26 ejs0 [n=eugen@29-132-124-91.pool.ukrtel.net] has joined #scheme 15:50:05 -!- ejs [n=eugen@nat.ironport.com] has quit [Read error: 110 (Connection timed out)] 15:51:01 -!- mejja [n=user@c-f6b6e555.023-82-73746f38.cust.bredbandsbolaget.se] has quit [Remote closed the connection] 15:53:29 -!- Quadrescence [n=quad@unaffiliated/quadrescence] has quit [Remote closed the connection] 15:54:13 Quadrescence [n=quad@unaffiliated/quadrescence] has joined #scheme 15:56:57 -!- ASau` [n=user@host197-231-msk.microtest.ru] has quit ["Off!"] 15:58:15 Mikoange1o [i=mikael@chemwarrior.meta.io] has joined #scheme 15:59:40 -!- Mr-Cat [n=Miranda@hermes.lanit.ru] has quit [Read error: 54 (Connection reset by peer)] 16:01:33 barney [n=bernhard@p549A24A6.dip0.t-ipconnect.de] has joined #scheme 16:02:30 athos [n=philipp@92.250.250.68] has joined #scheme 16:03:40 luz [n=davids@139.82.89.70] has joined #scheme 16:13:04 -!- jberg_ [n=johan@62.80-202-161.nextgentel.com] has quit [Read error: 110 (Connection timed out)] 16:16:10 jonrafkind [n=jon@wireless11.wireless.utah.edu] has joined #scheme 16:23:57 -!- apgwoz is now known as Guest91070 16:36:02 -!- Guest91070 [n=apgwoz@dsl253-076-034.nyc1.dsl.speakeasy.net] has quit [Read error: 110 (Connection timed out)] 16:41:46 bweaver [n=user@75.148.111.133] has joined #scheme 17:05:47 -!- Mr_Awesome [n=eric@isr5452.urh.uiuc.edu] has quit [Remote closed the connection] 17:07:08 ebzzry [n=ebzzry@124.217.83.0] has joined #scheme 17:07:24 Mr_Awesome [n=eric@isr5452.urh.uiuc.edu] has joined #scheme 17:08:15 eli: What happened to the .scm issue of PLT S? 17:09:27 -!- npe [n=npe@195.207.5.2] has quit [Remote closed the connection] 17:10:09 ebzzry: I committed a change in svn so that .ss is the default extension for saving (on windows; on linux you have to type the suffix anyway), and it shows .ss and .scm files as the default filter. 17:10:31 eli: Thanks a lot. 17:10:43 eli: What happened to that btw? Was that behavior intended? 17:12:12 Which one? 17:12:38 eli: The suffix that defaults to ".scm", I mean shows ".scm" only. 17:13:20 It was supposed to be like it is now -- but it did the right thing only on osx for some reason. 17:14:09 eli: OK, thanks anyway. Btw, I looked for you yesterday, but you seemed to be unavailable that time. Are you partly incharge of the stuff at docs.plt-scheme.org? 17:14:27 Yes. 17:14:49 eli: So it seems appropriate that I send errata reports to you then. 17:15:34 If it's bugs in the documentation pages, then it's best to send them as bug reports. (There's no way I'd have actually written all that text...) 17:15:45 eli: OK then. 17:15:58 But if they are quick and obvious typos, then I can commit fixes. 17:16:08 eli: OK 17:16:18 *Now to find those entries* 17:22:23 Btw, in what way can the presence of `result' at http://docs.plt-scheme.org/guide/contract-func.html#(part._contracts-range) make the whole expr valid? 17:24:36 Quadrescence: show-paren-mode 17:24:46 MichaelRaskin [n=MichaelR@gwh-1-177-mytn23k1.ln.rinet.ru] has joined #scheme 17:25:18 anyway, there is #emacs for those things. 17:27:03 -!- Cowmoo [n=Cowmoo@static-70-108-241-27.res.east.verizon.net] has quit [Read error: 104 (Connection reset by peer)] 17:27:12 sladegen: No, I meant where the whole form and all nested forms are highlighted (with the nested forms having increased intensity) 17:28:43 ah, well i don't use drscheme... try emacswiki.org, too. 17:29:22 The one thing that bugs me about emacs is the hard-coded keybindings. I don't know if drscheme isn't like that, but I do know emacs is terrible in that respect. 17:29:51 hard-coded keybindings...? are you serious? 17:30:06 I've never had to do so many hand acrobatics as with emacs. C-xC-s is literally jumping back and forth over the keyboard with each new key. 17:30:11 you mean default keybindings... 17:30:14 I have to use both control keys 17:30:21 Quadrescence: Are you looking for cparen? 17:30:33 ebzzry: I am not sure. 17:30:34 Well, default yeah... but how else are you going to do it when C-x is a whole subsystem of key bindings? 17:30:45 Quadrescence: Look for it at emacswiki.org 17:30:57 synx: It's doable. 17:31:16 synx: The various emacs manuals describe how to do it. 17:31:27 synx: I have such config. 17:31:38 synx: i never found it that bothersome... to actually try viper for example... 17:32:03 If I could get it so the keybindings I use stayed on the home row I might use emacs. I always end up just doing M-x-words-words-words though. 17:33:03 synx: What makes you think it's *that* difficult? I'm using Dvorak with Emacs and have my keybindings customized. 17:33:34 Part of it is my inability to settle on a given set of functions. 17:33:51 synx: The reason why emacs such keybindings is part historical. 17:34:06 has such* 17:35:18 Also the odd discrepency between the customization interface and just editing .emacs bugs me. Couple of times I set something in .emacs but had years ago set it differently as a customization option, and had no way of knowing that. 17:35:21 Quadrescence: Here is the direct link to cparen.el: http://users.tkk.fi/u/rsaikkon/software/elisp/cparen.el 17:35:59 Another thing that bugs me about emacs is its lisp is icky. :> 17:36:00 Mr-Cat [n=Mr-Cat@bahirkin1507.static.corbina.ru] has joined #scheme 17:36:04 synx: There are some things that are best done through Customize 17:36:10 I still don't really understand the difference between set and setq in emacs. 17:36:31 synx: RMS has stated before why Emacs Lisp is just that. 17:36:44 Well RMS can KMA 17:37:07 CaptainMorgan [n=CaptainM@c-75-68-42-94.hsd1.nh.comcast.net] has joined #scheme 17:37:10 synx: Let's keep the discussion on-topic. 17:37:29 synx: You may want to bring your Emacs concerns to #emacs where it's best addressed. 17:37:33 emacs buffers are hard to navigate through programatically. But that might be a problem of "buffers" in general.. 17:37:50 If I was actually looking for solutions and not just complaining, I would do exactly that ebzzry 17:37:50 The fact that elisp is bad is not something many people will dispute. 17:38:04 I agree with eli. 17:38:16 ebzzry: That `result' does look bogus, I've comitted a fix, guessing that it should have been `str' instead. 17:38:22 synx: It depends how much time you want to invest in Emac to make things *easier* 17:38:30 eli: Yup. 17:38:52 eli: I looked at it like a dozen times but I just can't find a way to make it valid. 17:38:56 minion: advice for synx 17:38:56 synx: #11942: Sure, but you have to have some understanding also. 17:39:08 thank you minion! 17:39:30 minion: advice for incubot 17:39:30 incubot: #11920: The error message is the Truth. The error message is God. 17:39:33 who, amongst other things, invented truth tables and taught Turing. 17:39:58 synx: btw, the best approach to understanding `set' is to just not use it. It's a bogus concept from darker times. 17:40:32 eli: `set' could still be used, but very sparingly. 17:40:49 I have never seen any case where I needed to use it. 17:40:54 drscheme sure is hella convenient for mred programming. 17:41:07 that kind of goes without saying though 17:41:08 Gosh, incubot! 17:41:10 And I *have* used Emacs *a lot*. 17:41:16 synx: Take a look at how much I mutilated the default conf of Emacs to make my life a little *easier* at: http://github.com/ebzzry/dotemacs/tree 17:41:31 (And still using it, though I'm not hacking it more, since it's doing everything I want it to do.) 17:41:43 uh ebzzry that's a webpage not an .emacs file 17:41:52 synx: huh 17:42:14 kniu [n=kniu@OVERLORD.RES.CMU.EDU] has joined #scheme 17:42:26 synx: Oh, is that so? 17:42:27 It says "Loading commit data" 17:43:13 synx: You'd have to use `git' to make things easier to view. 17:43:45 ah, elisp. sigh 17:44:40 ebzzry: you want me to download the entire directory? I don't know how to list stuff in git. 17:45:36 eli: I feel so guilty that I have to say non-schemey things. Will I get crucified for this? 17:45:54 "git co http://github.com/ebzzry/dotemacs/tree" fails badly 17:46:06 synx: It's "git clone" 17:46:08 ebzzry: what non-schemey thing did you say? 17:46:15 clone I mean. 17:46:17 eli: Those emacs things above. 17:46:22 git clone fails badly 17:46:24 synx: The clone url is listed 17:46:35 git co fails nicely and chides me properly to use clone. 17:46:44 synx: git clone git://github.com/ebzzry/dotemacs.git 17:46:46 foof: (fmt #f (num #x555555 2)) => "5592405" 17:46:48 Ah, well, the fact that elisp sucks or not is irrelevant to the fact that Emacs is still a very useful tool. 17:47:00 eli: But is it allowed to be discussed here? 17:47:00 So you do want me to use the webpage after all. 17:47:07 synx: no. 17:47:22 foof: while (fmt #f (num #xff 2)) => "11111111" 17:47:27 ebzzry: On this channel? I don't mind it, but I have no authority here... 17:47:39 whatever I got it, but still no .emacs file. 17:47:45 eli: I better speak about non-topic-related things very sparingly then. 17:48:06 ebzzry: besides, for many schemes Emacs is pretty much the only sane choice for an editor. 17:48:17 synx: Perform that command, not in your home directory. 17:48:24 (AFAICT, plt is an exception in that department.) 17:48:33 presto10 [n=user@cs181131.pp.htv.fi] has joined #scheme 17:48:33 eli: Yup. 17:48:55 plt is an exception it's true. I use emacs for chicken or scheme48 when I'm in those. 17:49:00 synx: The directory created after issuing that command is "dotemacs" 17:49:01 I still don't like it though. 17:49:10 So inconvenient and time consuming. 17:49:16 synx: Have you ever used Quack? 17:49:32 ebzzry: Yes I can see the directory, but there's no .emacs file. 17:49:37 I've never used Quack. 17:49:50 Don't ask me to google for Quack please :( 17:49:50 synx: It's because I'm using .emacs.d/init.el 17:50:07 synx: And that file trampolines the other required files. 17:50:09 Oh I forgot about that init.el thing. 17:50:16 http://www.neilvandyke.org/quack/ 17:50:43 Does "Customize" know enough to write to custom.el if you're using init.el? 17:50:45 synx: It's just an example how much I got just to make *my* life a little easier. Not necessarily to discuss heavily about, which is best done via other methods. 17:51:04 synx: Well, read the manuals. 17:51:14 eli: Quack is pretty decent, imho. 17:51:41 Which manuals ebzzry :p 17:51:48 synx: elisp manuals. 17:51:57 synx: and emacs manuals 17:51:59 Oh that really narrows it down. 17:52:08 synx: Yes, it does, honestly. 17:52:09 Only take me 3 days to read through those. 17:52:23 Sorry I think I should just stop talking. 17:52:42 eli: Thanks for the fixes wrt the docs. 17:54:01 synx: Maybe. More reading and testing will surely help a lot. 17:54:37 -!- a-s [n=user@92.81.117.113] has quit [Remote closed the connection] 17:55:10 synx: it all depends on your needs -- if you really need to use Emacs, (or if it presents enough advantages for you to think you need it), then reading such manuals and investing time in making Emacs do what you want is time well spent. 17:55:22 Or I could keep using drscheme which just works. 17:55:58 emacs is the way it is also partly becayse RMS has that KMA attitude, too. 17:56:00 synx: For PLT Scheme yes, I don't know with other schemes. 17:56:48 I used to use emacs a lot, but I ended up spending so much time on it that the rewards just weren't worth it. It's manuals are like trying to learn how to read with only a dictionary. 17:57:22 Then again once I stopped using gnus emacs stopped segfaulting so maybe I was pushing it a wee bit. 17:58:35 I just don't think I'm cut out for an advanced editor like it. 17:59:25 synx: It depends heavily on personal preferences, I myself always find Vi _faster_ to use for some tasks, but Emacs is way more customizable and extensible. 18:06:57 hotblack23 [n=jh@p5B054884.dip.t-dialin.net] has joined #scheme 18:15:33 -!- araujo [n=araujo@gentoo/developer/araujo] has quit ["Leaving"] 18:16:27 -!- jonrafkind [n=jon@wireless11.wireless.utah.edu] has quit [Connection timed out] 18:18:20 -!- mmc [n=mima@esprx02x.nokia.com] has quit ["Leaving."] 18:23:12 -!- ffd [n=ffd@cpe-24-27-73-108.tx.res.rr.com] has quit [Read error: 54 (Connection reset by peer)] 18:26:14 jonrafkind [n=jon@crystalis.cs.utah.edu] has joined #scheme 18:33:25 -!- Adamant [n=Adamant@unaffiliated/adamant] has quit [] 18:37:27 -!- xwl [n=user@114.246.89.53] has quit [Read error: 60 (Operation timed out)] 18:38:36 RageOfThou [n=RageOfTh@92.36.156.145] has joined #scheme 18:45:24 FunkyDrummer [n=RageOfTh@92.36.220.116] has joined #scheme 18:45:50 freenose [n=John@204.97.199.2] has joined #scheme 18:47:37 -!- freenose [n=John@204.97.199.2] has quit ["Leaving."] 18:49:55 Adamant [n=Adamant@c-76-29-188-22.hsd1.ga.comcast.net] has joined #scheme 18:52:37 -!- Mr-Cat [n=Mr-Cat@bahirkin1507.static.corbina.ru] has quit [Remote closed the connection] 18:56:34 -!- MrFahrenheit [n=RageOfTh@92.36.156.248] has quit [Read error: 110 (Connection timed out)] 18:57:20 -!- bweaver [n=user@75.148.111.133] has quit ["ERC Version 5.3 (IRC client for Emacs)"] 18:58:29 Cowmoo [n=Cowmoo@static-70-108-241-27.res.east.verizon.net] has joined #scheme 19:03:20 -!- RageOfThou [n=RageOfTh@92.36.156.145] has quit [Read error: 110 (Connection timed out)] 19:06:06 -!- Ragnaroek [i=54a66c54@gateway/web/ajax/mibbit.com/x-0e7cb993f1e7746c] has quit ["http://www.mibbit.com ajax IRC Client"] 19:06:27 Ragnaroek [i=54a66c54@gateway/web/ajax/mibbit.com/x-e1d81de3465bc262] has joined #scheme 19:13:29 -!- MichaelRaskin [n=MichaelR@gwh-1-177-mytn23k1.ln.rinet.ru] has left #scheme 19:13:53 MichaelRaskin [n=MichaelR@gwh-1-177-mytn23k1.ln.rinet.ru] has joined #scheme 19:14:43 couldn't resist: http://www.youtube.com/watch?v=yGFRi_ueq-M 19:20:28 ebzzry_ [n=ebzzry@124.217.73.51] has joined #scheme 19:32:23 -!- ebzzry [n=ebzzry@124.217.83.0] has quit [Read error: 110 (Connection timed out)] 19:37:32 -!- ct2rips [n=ct2rips@blfd-4db1d89b.pool.einsundeins.de] has quit ["Verlassend"] 19:43:53 forcer [n=forcer@g224064084.adsl.alicedsl.de] has joined #scheme 19:44:49 -!- p1dzkl [i=p1dzkl@81.167.54.222.static.lyse.net] has quit [Read error: 54 (Connection reset by peer)] 19:45:48 -!- Fare [n=Fare@ita4fw1.itasoftware.com] has quit [Remote closed the connection] 19:46:32 Fare [n=Fare@ita4fw1.itasoftware.com] has joined #scheme 19:46:36 so  you guys like Scheme? 19:46:57 no, we just hate it less 19:47:05 What the hell is Scheme? 19:47:32 p1dzkl [i=p1dzkl@81.167.54.222.static.lyse.net] has joined #scheme 19:48:08 Mikoange1o: you violated the first rule of lambda-club; now gtho 19:48:29 -!- ebzzry_ [n=ebzzry@124.217.73.51] has quit ["Leaving"] 19:49:35 klutometis: the zeroth law states it's okay to violate the first law of lambda-club, as long as it benefits humanity as a whole 19:49:36 o_O 19:50:17 I don't even know what lambda-club is 19:50:17 our founder, R. Tyler Durden 19:50:24 what is the first rule of lambda-club? 19:50:34 minion: advice for synx 19:50:35 synx: #11925: Gosh, that wasn't very bright, was it? 19:50:49 on point as always, minion 19:51:14 you people are weird 19:51:32 oh, I get it, it's some kind of movie rference 19:51:34 Intriguing 19:52:52 the book was better 19:54:08 they usually are... unless the book is made after the movie of course 19:56:28 Mikoange1o: you speak of these "movie" things as though they inhabit a parallel universe; i'm jealous 19:59:05 kilimanjaro [n=kilimanj@70.116.95.163] has joined #scheme 20:04:40 parallel universes lead me to ponder. 20:04:56 zbigniew: nice; there's also the little known negative-first law, which states that no one shall harm my kibbutz 20:04:57 if there were two of them, could you call each of them a universe? 20:05:08 wouldn't that make them just verses? 20:05:40 synx: interesting; polyverses, then. congratulations: another meme-worth neologism 20:06:02 w00t 20:07:17 presto10` [n=user@cs181131.pp.htv.fi] has joined #scheme 20:07:32 they don't rhyme, and are not really parallel -- so uniprose is more like it. 20:07:49 -!- kniu [n=kniu@OVERLORD.RES.CMU.EDU] has quit [Read error: 110 (Connection timed out)] 20:07:54 -!- jonrafkind [n=jon@crystalis.cs.utah.edu] has quit ["Leaving"] 20:07:56 multiverse is the lingo I'e most frequently encountered 20:08:09 jonrafkind [n=jon@crystalis.cs.utah.edu] has joined #scheme 20:08:20 but to me both sound like they're a /collection/ of universes, not individual universes that happen to not be the only 20:08:38 kniu [n=kniu@CMU-284828.WV.CC.CMU.EDU] has joined #scheme 20:08:58 Mikoange1o: multiverse is superior to polyverse in that it doesn't mix greek and latin stems 20:09:14 but isn't that what language is all about? 20:09:17 but the polyverse is ALL about mixing stuff 20:09:24 those universes interact 20:10:33 in some theories, at least 20:10:41 Mikoange1o: i'm not sure; if language weren't continent, would it be coherent? you'd have pure entropy, otherwise 20:12:01 benny` [n=benny@i577A1209.versanet.de] has joined #scheme 20:12:49 exexex [n=chatzill@88.234.14.80] has joined #scheme 20:17:26 indeed 20:17:28 sphex_ [n=nobody@modemcable185.138-56-74.mc.videotron.ca] has joined #scheme 20:19:57 klutometis: ah, the fabled Minus-one law 20:20:01 -!- sphex [n=nobody@modemcable185.138-56-74.mc.videotron.ca] has quit [Read error: 60 (Operation timed out)] 20:21:33 -!- presto10 [n=user@cs181131.pp.htv.fi] has quit [Read error: 110 (Connection timed out)] 20:22:31 incubot: a can of tea was the most satisfying coda to a half-year of diet crack 20:22:34 I like this explanation in the Hacker Diet: 20:22:38 -!- p1dzkl [i=p1dzkl@81.167.54.222.static.lyse.net] has quit [Remote closed the connection] 20:23:05 Mr-Cat [n=Mr-Cat@bahirkin1507.static.corbina.ru] has joined #scheme 20:24:43 jberg [n=johan@62.80-202-161.nextgentel.com] has joined #scheme 20:25:43 Judofyr [n=Judofyr@c859EBF51.dhcp.bluecom.no] has joined #scheme 20:25:53 -!- benny [n=benny@i577A14D8.versanet.de] has quit [Read error: 113 (No route to host)] 20:29:04 -!- glogic_ is now known as glogic 20:29:28 -!- jewel_ is now known as jewel 20:29:30 p1dzkl [i=p1dzkl@81.167.54.222.static.lyse.net] has joined #scheme 20:31:08 -!- Nshag [i=user@Mix-Orleans-106-2-129.w193-248.abo.wanadoo.fr] has quit ["Quitte"] 20:33:00 -!- MichaelRaskin [n=MichaelR@gwh-1-177-mytn23k1.ln.rinet.ru] has left #scheme 20:33:28 MichaelRaskin [n=MichaelR@gwh-1-177-mytn23k1.ln.rinet.ru] has joined #scheme 20:47:09 HOLY SHIT iT'S Judofyr! 20:47:19 :O 20:47:25 you're in #scheme too? 20:47:29 Just joined 20:47:51 been here some weeks. mostly idling, though 20:47:54 Just picked up the language 20:47:58 (it's insane) 20:48:11 I'm going through SICP :-) 20:48:20 or, was supposed to 20:48:49 eh, SICP 20:49:15 and The Little Schemer 20:49:18 what's SICP? 20:49:30 I read Teach Yourself Scheme in Fixnum Days 20:49:39 it was  pretty weird 20:49:40 It's a book on the structure and interpretation of scheme programs. 20:49:50 computer programs* 20:50:08 -!- jberg [n=johan@62.80-202-161.nextgentel.com] has quit [Read error: 60 (Operation timed out)] 20:50:10 http://mitpress.mit.edu/sicp/full-text/book/book-Z-H-4.html 20:50:20 some would say computer programs Judofyr. 20:50:34 it's like the holy bible of computer science (for some) 20:50:43 I haven't read so many bibles, so I'm not sure yet 20:52:04 I found SICP useful. Really any good algorithms book will teach you what you need to know. 20:53:58 -!- forcer [n=forcer@g224064084.adsl.alicedsl.de] has quit [Remote closed the connection] 20:57:22 -!- ejs0 [n=eugen@29-132-124-91.pool.ukrtel.net] has quit [Read error: 60 (Operation timed out)] 21:03:26 minion: chant 21:03:27 MORE CONCERNED 21:05:25 minion: be concerned 21:05:26 you speak nonsense 21:05:29 :p 21:05:39 -!- Ragnaroek [i=54a66c54@gateway/web/ajax/mibbit.com/x-e1d81de3465bc262] has quit ["http://www.mibbit.com ajax IRC Client"] 21:06:24 jberg [n=johan@62.80-202-161.nextgentel.com] has joined #scheme 21:06:44 -!- kniu [n=kniu@CMU-284828.WV.CC.CMU.EDU] has quit ["Leaving"] 21:08:19 -!- luz [n=davids@139.82.89.70] has quit ["Client exiting"] 21:08:58 ejs0 [n=eugen@102-195-124-91.pool.ukrtel.net] has joined #scheme 21:16:04 minion: advice 11944 for leppie 21:16:04 leppie: Yes, that's what it's supposed to do when you say that. 21:16:19 haha 21:17:08 kniu [n=kniu@OVERLORD.RES.CMU.EDU] has joined #scheme 21:17:27 I need a a way to call a function and return early if it takes too long 21:22:08 -!- presto10` [n=user@cs181131.pp.htv.fi] has quit [Read error: 110 (Connection timed out)] 21:22:32 -!- barney [n=bernhard@p549A24A6.dip0.t-ipconnect.de] has quit [Remote closed the connection] 21:23:33 -!- Adamant [n=Adamant@unaffiliated/adamant] has quit [] 21:23:48 zane` [n=zane@c-66-31-28-121.hsd1.ma.comcast.net] has joined #scheme 21:25:20 nibble70 [n=nibble70@net-93-150-24-240.t2.dsl.vodafone.it] has joined #scheme 21:28:58 mmc [n=mima@cs160181.pp.htv.fi] has joined #scheme 21:29:35 -!- subversus [i=elliot@loveturtle.net] has quit [Read error: 113 (No route to host)] 21:36:43 i can i have a static varible in a funtion like c++? or a workaround ? 21:36:59 what do you mean? 21:38:27 something like (define foo (let ((bar 1)) (lambda (x) (let ((sum (+ bar x)) (set! bar sum) sum))) ? 21:39:01 let-over-lambda 21:39:12 hmm let me see 21:40:34 gweiqi [n=greg@69.120.126.163] has joined #scheme 21:40:40 mejja [n=user@c-f6b6e555.023-82-73746f38.cust.bredbandsbolaget.se] has joined #scheme 21:42:24 -!- Fare [n=Fare@ita4fw1.itasoftware.com] has quit ["Leaving"] 21:45:49 -!- zane` is now known as Vaeshir 21:50:23 geckosenator: threads 21:51:02 hmm 21:53:01 sohum [n=sohum@unaffiliated/sohum] has joined #scheme 21:53:36 -!- jberg [n=johan@62.80-202-161.nextgentel.com] has quit [Read error: 60 (Operation timed out)] 21:53:41 you probably need to 'catch' the thread-abort condition to return something useful 21:54:14 ok 21:54:22 I'm using chicken at the moment 21:54:37 -!- Elonetaru [n=elone@c-71-202-143-119.hsd1.ca.comcast.net] has quit [Read error: 104 (Connection reset by peer)] 21:54:50 unless you want to check the time every now and again inside your running loop 21:55:03 depends how quick you want to exit 21:55:16 or how 21:55:29 I just want to abort after a certain amount of time 21:55:50 since some of the computation takes milliseconds, and other times it takes years 21:55:50 i would try use threads if its available 21:56:05 and it takes a bunch of overhead within the algorithm to check this case 21:56:14 well thats what I would do naturally on .NET in the same situation 21:56:23 ok 21:56:24 and probably any other platform 21:56:33 srfi-18 ? 21:56:38 I never used .net 21:56:42 a-s [n=user@92.81.117.113] has joined #scheme 21:57:03 it depends what chicken offers 21:57:14 it will probably be implementation specific 21:57:28 but easily portable 21:59:44 ok, so I'm trying to use call/cc to non-local exit and turn a (define (foo args) ... (or (foo args') (foo args''))) into a tail-recursive variant 21:59:52 but it still stack overflows on me 22:00:30 what are you doing? 22:00:38 dpll 22:01:50 you want both calls to foo to be tail recursive/ 22:01:51 ? 22:02:08 that should be possible, right? 22:03:25 lolcow [n=lolcow@dsl-243-51-87.telkomadsl.co.za] has joined #scheme 22:03:25 -!- leppie [n=lolcow@dsl-243-51-87.telkomadsl.co.za] has quit [Read error: 54 (Connection reset by peer)] 22:03:47 -!- lolcow is now known as leppie 22:03:54 yes, i think so 22:03:59 rewrite in a cps style 22:04:12 grrrr, stupid internet 22:04:17 -!- nibble70 [n=nibble70@net-93-150-24-240.t2.dsl.vodafone.it] has left #scheme 22:04:50 sohum pasted "transforming non-tail-call into a tail-call" at http://paste.lisp.org/display/78767 22:05:22 annodomini [n=lambda@130.189.179.215] has joined #scheme 22:05:52 sohum annotated #78767 "What I tried, using call/cc" at http://paste.lisp.org/display/78767#1 22:07:57 I just want to know a) if that has the semantics I want and b) why/how can I find whatever function is causing the stack overflow 22:08:12 that 'improvement' just seems wrong in so many places :) 22:08:41 it does? 22:08:43 You want a result, right sohum? 22:08:54 what is the purpose of the call/cc? 22:08:58 (or a b) for instance. 22:09:37 leppie: I think e's using the call/cc to produce a result, without having to accumulate it anywhere. Turning for-each into findf for instance. 22:11:01 I can only guess (exit #t) is called somewhere in the . . . 22:11:04 if so, that would introduce even more stack space (given the 'missing' or) 22:11:05 yea, there's an (exit #t) in the code that I haven't shown 22:11:50 I don't think it would introduce more stack space, but I don't think it'd really be tail recursive... maybe it would for the second call but not the first. 22:12:01 -!- Judofyr [n=Judofyr@c859EBF51.dhcp.bluecom.no] has quit [Remote closed the connection] 22:12:16 yeah, it probably add no more, but it would not be any less :) 22:12:18 is there any way to check that? compile, outputting all tail-recursive modifications? 22:12:33 *optimisations 22:12:52 Not that I know of... it's pretty obvious though. 22:12:53 sohum: tail calls happens at the specified places in the spec 22:13:42 If you call a procedure, and you have to perform some calculation after that procedure is finished, then it's not tail recursive. Otherwise it is. 22:13:47 forcer [n=forcer@e179198226.adsl.alicedsl.de] has joined #scheme 22:14:14 That's why people like CPS style so much, because it never requires anything after a procedure is finished. 22:14:27 Judofyr [n=Judofyr@c859EBF51.dhcp.bluecom.no] has joined #scheme 22:14:28 how is "after" defined? as in (after (foo)) or (foo) (after)? 22:14:31 Yet can perform many of the same tasks. I dunno, explicit stack eh. 22:14:54 You mean (begin (foo) (after))? 22:15:00 is there no way to make to '2 way recursion into a single recursion' ? 22:15:01 synthase [n=synthase@68.63.19.212] has joined #scheme 22:15:02 yea 22:15:12 Then yes, both are after. 22:15:28 hmm. that's annoying 22:15:33 (if #t (foo) (after)) is still tail recursive though. It never gets to (after). 22:15:38 -!- Judofyr [n=Judofyr@c859EBF51.dhcp.bluecom.no] has quit [Remote closed the connection] 22:16:08 it's necessary sohum. If you want to do something after a procedure is finished, you can't discard the current procedure's state. 22:16:28 I suppose. so what's the option here? 22:16:37 write the function to try both? 22:16:45 well, I like your second solution actually. 22:17:22 oh? It doesn't exactly help, though, I still blow the stack 22:17:29 ... (or (foo ...) (foo ...)) is not tail recursive on either one of those, since it has to get both their results and or them. However it may never call the second one, if the first one returns true, so that's efficient too. 22:18:04 But (foo ...) (foo ...)) is tail recursive on the second foo, since it doesn't have to or anything. And if you find your result in the first one, you call (exit) and it never calls the second one. 22:18:25 *doesn't have to perform 'or' on any results 22:19:09 It still might blow the stack though, yes. Are you doing some sort of operation on a binary tree structure? 22:19:36 ok, that's how I thought they'd work. Nice to see I still have reading comprehension 22:19:39 effectively 22:19:42 it's dpll, like I said 22:20:26 if the base cases don't hold, you find a new literal to split on and try (foo (literal . #t)) and (foo (literal . #f)) 22:20:32 what's dpll... 22:21:10 -!- Mr-Cat [n=Mr-Cat@bahirkin1507.static.corbina.ru] has quit [Remote closed the connection] 22:21:11 oh I see it hm... 22:21:15 satisfiability solver, for logical formulas. details not relevant to this discussion 22:23:21 sphex [n=nobody@modemcable185.138-56-74.mc.videotron.ca] has joined #scheme 22:25:08 I'm trying to wrap my head around how a call to (foo (literal)) could try both, but the only things I can think of just push the non-tail-call recursion further down the call stack 22:26:06 sometimes you cant help it :( 22:26:49 I can't fathom any way to pare it down more. You already have half of it tail recursive, but no way to ensure that the second (foo) is called if you don't save the stack while the first one is called. 22:26:55 Adamant [n=Adamant@c-76-29-188-22.hsd1.ga.comcast.net] has joined #scheme 22:27:00 -!- puchacz [n=puchacz@87-194-5-99.bethere.co.uk] has quit [Remote closed the connection] 22:27:13 I bet you could do it with lazy scheme :p 22:27:40 heh 22:28:15 ejs [n=eugen@102-195-124-91.pool.ukrtel.net] has joined #scheme 22:30:31 how about using an accumilating queue for the second part? 22:31:24 ? 22:32:29 so you call the first test tail recursively, and capture the second parts argument, then when the first parts does not suceed, you try the queue 22:32:56 grumble explicit stack grumble 22:33:40 synx? 22:33:54 you'd basically be dropping large amounts of data onto the queue, given that the one arg isn't something I /want/ to duplicate needlessly 22:33:59 *zbigniew* feeds synx a Chicken drumstick 22:34:10 but I suppose dropping it on the heap instead of the stack is better 22:34:28 leppie: you could just capture the second part's argument in the stack, and not create a queue yourself. 22:34:37 *synx* omnomnom 22:34:52 synx: yeah, but im too drunk to figure that one out :) 22:35:20 It's called not using tail recursion :3 22:35:27 -!- sphex_ [n=nobody@modemcable185.138-56-74.mc.videotron.ca] has quit [Read error: 110 (Connection timed out)] 22:35:41 ok, yall're confusing me now 22:35:56 me too, long time now l;) 22:36:03 minion: advice for everybody 22:36:03 everybody: #11956: Well, it might be more intuitive that way, but it would also be useless. 22:36:14 *sohum* *snerk* 22:36:50 it's so much more fun to code in 'dumb' languages when you are drunk :( 22:37:10 incubot: dumb languages, such as the language of love 22:37:13 like..just..general ..languages 22:37:21 ok, kirk 22:37:34 minion: like the spoken word? 22:37:35 watch out, you'll make krystof angry 22:45:18 -!- ejs0 [n=eugen@102-195-124-91.pool.ukrtel.net] has quit [Read error: 110 (Connection timed out)] 22:47:14 tail-recursive confusion, the worst there is ;p 22:52:18 rotty: Thanks, that's odd. 22:55:06 -!- annodomini [n=lambda@wikipedia/lambda] has quit [] 22:57:58 -!- kilimanjaro [n=kilimanj@70.116.95.163] has quit ["Leaving"] 23:01:28 -!- jewel [n=jewel@dsl-247-205-254.telkomadsl.co.za] has quit [Read error: 113 (No route to host)] 23:01:38 GreyLensman [n=ray@c-76-108-236-161.hsd1.fl.comcast.net] has joined #scheme 23:03:13 -!- alaricsp [n=alaricsp@217.205.201.45] has quit [] 23:08:20 proq` [n=user@38.100.211.40] has joined #scheme 23:16:27 aleix [n=aleix@46.Red-83-61-3.dynamicIP.rima-tde.net] has joined #scheme 23:16:39 -!- aleix [n=aleix@46.Red-83-61-3.dynamicIP.rima-tde.net] has quit [Client Quit] 23:18:52 -!- Edico [n=Edico@unaffiliated/edico] has quit ["Leaving"] 23:20:16 -!- ejs [n=eugen@102-195-124-91.pool.ukrtel.net] has quit ["This computer has gone to sleep"] 23:21:27 -!- forcer [n=forcer@e179198226.adsl.alicedsl.de] has quit [Remote closed the connection] 23:21:37 forcer [n=forcer@e179198226.adsl.alicedsl.de] has joined #scheme 23:25:16 araujo [n=araujo@gentoo/developer/araujo] has joined #scheme 23:27:08 ejs [n=eugen@102-195-124-91.pool.ukrtel.net] has joined #scheme 23:30:52 -!- kazzmir [n=kazzmir@c-98-202-86-149.hsd1.ut.comcast.net] has quit [Read error: 113 (No route to host)] 23:32:10 -!- hotblack23 [n=jh@p5B054884.dip.t-dialin.net] has quit [Read error: 60 (Operation timed out)] 23:33:54 rotty: I'm guessing maybe Dybvig's algorithm doesn't work for base 2. I won't have time to fix it until Monday though. 23:34:52 annodomini [n=lambda@c-75-69-96-104.hsd1.nh.comcast.net] has joined #scheme 23:34:54 -!- benny` is now known as benny 23:34:59 kazzmir [n=kazzmir@c-98-202-86-149.hsd1.ut.comcast.net] has joined #scheme 23:37:22 luz [n=davids@189.122.121.232] has joined #scheme 23:40:08 -!- Adamant [n=Adamant@unaffiliated/adamant] has quit [] 23:41:50 Adamant [n=Adamant@c-76-29-188-22.hsd1.ga.comcast.net] has joined #scheme 23:44:13 ok, so using a queue seems to work, in that the code's now been running for ~10 minutes and the stack hasn't blown out yet 23:45:00 :) how much memory you got? 23:46:18 Seriously, why does gcc insist on giving 500 lines of meaningless syntax errors from undefined types, obscuring the one real error which is that an include file wasn't found? 23:46:35 that's how c works 23:46:48 primitive macros :) 23:47:09 let's see, it's using ... 66% of my 1.5gb of ram 23:47:11 ...yeesh 23:47:15 You see the tail end of the explosion, you know what happened, but sometimes it's helpful to know _which_ include file wasn't found. 23:47:29 a gig of ram 23:47:33 sohum: you gonna have to try solve it faster :) 23:47:47 And for some reason the terminal on OS X sometimes refuses to preserve scrolled lines. 23:47:58 I know, this is the non-optimised variant we're supposed to log the time-to-solve for 23:50:51 -!- GreyLensman [n=ray@c-76-108-236-161.hsd1.fl.comcast.net] has left #scheme 23:53:40 Lemonator [n=kniu@CMU-284828.WV.CC.CMU.EDU] has joined #scheme 23:53:45 -!- kniu [n=kniu@OVERLORD.RES.CMU.EDU] has quit [Read error: 110 (Connection timed out)] 23:55:30 jberg [n=johan@62.80-202-161.nextgentel.com] has joined #scheme 23:59:48 -!- athos [n=philipp@92.250.250.68] has quit ["leaving"]