2014-09-20T00:02:17Z slmult0_z_y_h_g quit (Ping timeout: 245 seconds) 2014-09-20T00:05:39Z jusss quit (Quit: ERC Version 5.2 (IRC client for Emacs)) 2014-09-20T00:05:44Z slmult0_z_y_h_g joined #scheme 2014-09-20T00:12:16Z oleo is now known as Guest71140 2014-09-20T00:13:52Z oleo__ joined #scheme 2014-09-20T00:15:04Z Guest71140 quit (Ping timeout: 244 seconds) 2014-09-20T00:17:15Z zlrth quit (Ping timeout: 272 seconds) 2014-09-20T00:20:52Z jlongster quit (Ping timeout: 240 seconds) 2014-09-20T00:22:40Z Rodya_ joined #scheme 2014-09-20T00:23:45Z Guest_ joined #scheme 2014-09-20T00:24:03Z Guest_: I didnt know Scheme was so popular... Hi I have to code in Scheme for school. Im trying to do an assignment, which shouldnt be too difficult. Can someone tell me why I am getting an error message? 2014-09-20T00:25:07Z Guest_: http://prntscr.com/4og5c3 2014-09-20T00:29:38Z Kabaka joined #scheme 2014-09-20T00:31:33Z kongtomorrow quit 2014-09-20T00:33:02Z emma joined #scheme 2014-09-20T00:33:07Z bjz quit (Ping timeout: 245 seconds) 2014-09-20T00:34:16Z kongtomorrow joined #scheme 2014-09-20T00:35:48Z pyro-_: Guest_: looks like your scheme implementation has a function named min which it doesn't want you to override 2014-09-20T00:36:14Z Guest_: Its ok I dont need min 2014-09-20T00:36:26Z pyro-_: just choose a different variable name 2014-09-20T00:37:15Z Guest_: Its supposed to be seconds and minutes 2014-09-20T00:37:51Z pyro-_: better to call it seconds and minutes then 2014-09-20T00:38:13Z emma quit (Ping timeout: 260 seconds) 2014-09-20T00:38:32Z Guest_: I used the variables mins and secs, but then there was no error message or answer XD 2014-09-20T00:38:33Z emma joined #scheme 2014-09-20T00:39:05Z pyro-_: well, you only have definitions there 2014-09-20T00:39:26Z Guest_: (define au 93000000000) (define c 186000) (define sec (/ au c)) (/ sec 60) I got this 2014-09-20T00:43:15Z emma quit (Ping timeout: 246 seconds) 2014-09-20T00:43:47Z common-lisper quit (Remote host closed the connection) 2014-09-20T00:44:45Z emma joined #scheme 2014-09-20T00:48:04Z jusss joined #scheme 2014-09-20T00:49:27Z emma quit (Ping timeout: 245 seconds) 2014-09-20T00:49:47Z _5kg_ quit (Ping timeout: 272 seconds) 2014-09-20T00:50:46Z _5kg_ joined #scheme 2014-09-20T00:51:19Z Guest_: I am trying to solve a quadratic equation using scheme, another one of my assignments. The equation is a X^2 - 6X + 13 = 0. I wrote (define q_equation (+ (expt x 2) (* x -6) 13)) (define q_equation 0) (+ x 0) but the problem is, x isnt defined. 2014-09-20T00:52:12Z vanila: (define (q_equation x) ...) to make it a function of x 2014-09-20T00:55:51Z Guest_: How can I say (+ (expt x 2) (* x -6) 13)) equals 0 2014-09-20T00:56:20Z vanila: Guest_, scheme the programming language can't do things like solving equations 2014-09-20T00:56:57Z vanila: Gerald Sussman wrote a library that lets you do this but in normal scheme you'd need to program the quadratic formula sqrt(b^2-4ac) stuff by hand 2014-09-20T00:58:33Z Guest_: http://bert.stuy.edu/pbrooks/fall2014/materials/intro/scheme_homework_1.html question 4 2014-09-20T00:58:34Z rudybot: http://tinyurl.com/mnptaev 2014-09-20T00:59:19Z vanila: Guest_, why not write a function (define (solve-quadratic-equation a b c) ...) 2014-09-20T00:59:45Z vanila: then you can test it like this (q_equation (solve-quadratic-equation 2 -6 13)) and ti shoudl give 0 2014-09-20T00:59:52Z jusss quit (Ping timeout: 256 seconds) 2014-09-20T01:00:28Z Guest_: Im givin the equation and Im supposed to find the solutions 2014-09-20T01:00:32Z Guest_: The 2 values of x 2014-09-20T01:00:40Z Guest_: * given 2014-09-20T01:01:21Z vanila: are you familair with the quadratic formula? http://tothereal.files.wordpress.com/2013/05/quadratic-formula.jpg 2014-09-20T01:01:52Z Guest_: Oh thanks 2014-09-20T01:01:57Z Guest_: Forgot about that 2014-09-20T01:03:15Z emma joined #scheme 2014-09-20T01:08:33Z emma quit (Ping timeout: 272 seconds) 2014-09-20T01:09:06Z emma joined #scheme 2014-09-20T01:12:12Z Guest_ quit (Quit: Page closed) 2014-09-20T01:12:50Z theseb quit (Quit: Leaving) 2014-09-20T01:13:39Z zlrth joined #scheme 2014-09-20T01:14:29Z emma quit (Ping timeout: 272 seconds) 2014-09-20T01:16:08Z common-lisper joined #scheme 2014-09-20T01:18:28Z jlongster joined #scheme 2014-09-20T01:18:31Z kongtomorrow quit 2014-09-20T01:30:03Z emma joined #scheme 2014-09-20T01:34:07Z zacts: vanila: x = [ -b +- sqrt( b^2 - 4ac ) ] / 2a 2014-09-20T01:34:33Z vanila: thanks zacts 2014-09-20T01:34:48Z zacts: when 0 = ax^2 + bx + c 2014-09-20T01:34:51Z zacts: =) 2014-09-20T01:35:19Z emma quit (Ping timeout: 272 seconds) 2014-09-20T01:36:01Z araujo quit (Ping timeout: 272 seconds) 2014-09-20T01:36:31Z emma joined #scheme 2014-09-20T01:39:22Z kongtomorrow joined #scheme 2014-09-20T01:41:41Z emma quit (Ping timeout: 260 seconds) 2014-09-20T01:42:36Z emma joined #scheme 2014-09-20T01:44:17Z Guest_ joined #scheme 2014-09-20T01:45:33Z Guest_: I dont know what I did wrong. Im trying to solve the quadratic equation x^2 - 6x + 13 = 0. http://prntscr.com/4ogpx8 2014-09-20T01:45:49Z Guest_: I have a lot of variables, but the code should be correct... 2014-09-20T01:46:38Z vanila: is 3+2i wrong? 2014-09-20T01:50:59Z emma quit (Ping timeout: 272 seconds) 2014-09-20T01:51:17Z Guest_: I dont know... 2014-09-20T01:51:18Z emma joined #scheme 2014-09-20T01:51:37Z vanila: why don't you test it 2014-09-20T01:51:47Z vanila: (define (q_equation x) (+ (expt x 2) (* x -6) 13)) 2014-09-20T01:51:54Z vanila: an dsee if (q_equation 3+2i) is 0 2014-09-20T01:53:52Z tobik quit (Ping timeout: 240 seconds) 2014-09-20T01:55:56Z tobik joined #scheme 2014-09-20T01:56:03Z emma quit (Ping timeout: 246 seconds) 2014-09-20T01:57:04Z jlongster quit (Ping timeout: 260 seconds) 2014-09-20T02:03:02Z emma joined #scheme 2014-09-20T02:03:23Z jusss joined #scheme 2014-09-20T02:03:28Z jusss: d 2014-09-20T02:10:11Z Guest_ quit (Quit: Page closed) 2014-09-20T02:13:02Z common-lisper quit (Remote host closed the connection) 2014-09-20T02:15:59Z nisstyre quit (Quit: WeeChat 1.0) 2014-09-20T02:16:16Z nisstyre joined #scheme 2014-09-20T02:16:21Z emma quit (Ping timeout: 246 seconds) 2014-09-20T02:17:12Z jlongster joined #scheme 2014-09-20T02:18:45Z araujo joined #scheme 2014-09-20T02:18:45Z araujo quit (Changing host) 2014-09-20T02:18:45Z araujo joined #scheme 2014-09-20T02:23:32Z jeapostrophe joined #scheme 2014-09-20T02:23:49Z emma joined #scheme 2014-09-20T02:28:57Z emma quit (Ping timeout: 245 seconds) 2014-09-20T02:29:27Z kongtomorrow quit 2014-09-20T02:29:39Z emma joined #scheme 2014-09-20T02:30:04Z zlrth quit (Remote host closed the connection) 2014-09-20T02:31:07Z slmult0_z_y_h_g quit (Ping timeout: 272 seconds) 2014-09-20T02:32:10Z slmult0_z_y_h_g joined #scheme 2014-09-20T02:34:46Z zlrth joined #scheme 2014-09-20T02:38:24Z emma quit (Ping timeout: 246 seconds) 2014-09-20T02:38:57Z emma joined #scheme 2014-09-20T02:39:41Z nisstyre quit (Quit: WeeChat 1.0) 2014-09-20T02:40:32Z nisstyre joined #scheme 2014-09-20T02:41:18Z nisstyre quit (Changing host) 2014-09-20T02:41:18Z nisstyre joined #scheme 2014-09-20T02:55:46Z emma quit (Ping timeout: 258 seconds) 2014-09-20T02:56:17Z emma joined #scheme 2014-09-20T03:06:56Z common-lisper joined #scheme 2014-09-20T03:07:48Z alexei___ joined #scheme 2014-09-20T03:10:53Z alexei_ quit (Ping timeout: 260 seconds) 2014-09-20T03:13:07Z kongtomorrow joined #scheme 2014-09-20T03:13:23Z emma quit (Ping timeout: 240 seconds) 2014-09-20T03:14:24Z emma joined #scheme 2014-09-20T03:16:36Z P4Titan joined #scheme 2014-09-20T03:16:53Z P4Titan: How do I pass the return of (values a b c) into a function? 2014-09-20T03:20:14Z vanila: MULTIPLE-VALUE-BIND perhaps 2014-09-20T03:20:39Z P4Titan: could you please give me an example 2014-09-20T03:24:08Z emma quit (Remote host closed the connection) 2014-09-20T03:24:35Z emma joined #scheme 2014-09-20T03:27:25Z P4Titan left #scheme 2014-09-20T03:28:46Z slmult0_z_y_h_g_ joined #scheme 2014-09-20T03:28:49Z slmult0_z_y_h_g quit (Ping timeout: 244 seconds) 2014-09-20T03:29:09Z emma quit (Ping timeout: 246 seconds) 2014-09-20T03:30:25Z emma joined #scheme 2014-09-20T03:35:37Z emma quit (Ping timeout: 260 seconds) 2014-09-20T03:36:13Z emma joined #scheme 2014-09-20T03:37:17Z pjb: vanila: this is #scheme, here it's call-with-values 2014-09-20T03:37:42Z pjb: minion: memo for P4Titan: just read about call-with-values in http://www.schemers.org/Documents/Standards/R5RS/HTML/ 2014-09-20T03:48:58Z emma quit (Ping timeout: 244 seconds) 2014-09-20T03:50:18Z emma joined #scheme 2014-09-20T03:55:10Z emma quit (Ping timeout: 244 seconds) 2014-09-20T04:01:21Z vinleod joined #scheme 2014-09-20T04:02:02Z davexunit quit (Quit: Later) 2014-09-20T04:03:12Z jlongster quit (Ping timeout: 245 seconds) 2014-09-20T04:05:25Z jusss quit (Quit: ERC Version 5.2 (IRC client for Emacs)) 2014-09-20T04:09:41Z jeapostrophe quit (Ping timeout: 272 seconds) 2014-09-20T04:11:12Z emma joined #scheme 2014-09-20T04:14:22Z mercwithamouth quit (Ping timeout: 240 seconds) 2014-09-20T04:33:52Z emma quit (Ping timeout: 260 seconds) 2014-09-20T04:40:32Z emma joined #scheme 2014-09-20T04:40:42Z emma quit (Changing host) 2014-09-20T04:40:43Z emma joined #scheme 2014-09-20T04:49:07Z kongtomorrow quit 2014-09-20T04:54:01Z emma quit (Ping timeout: 272 seconds) 2014-09-20T04:54:52Z emma joined #scheme 2014-09-20T05:05:15Z kongtomorrow joined #scheme 2014-09-20T05:06:41Z araujo quit (Quit: Leaving) 2014-09-20T05:07:12Z Rodya_ quit (Quit: Ex-Chat) 2014-09-20T05:11:26Z kongtomorrow quit 2014-09-20T05:18:56Z vanila: http://repository.readscheme.org/ftp/papers/orbit-thesis.pdf 2014-09-20T05:19:14Z vanila: im reading this but i dont fully understand 4.2 ecsape analysis on page 37 2014-09-20T05:19:44Z vanila: "I procedure is said to /escape/ if the compiler cannot identify all the places where the procedure is being called." 2014-09-20T05:30:37Z tcsc quit (Quit: computer sleeping) 2014-09-20T05:36:40Z ijp: okay 2014-09-20T05:50:58Z _tca quit (Ping timeout: 260 seconds) 2014-09-20T05:50:58Z gluegadget quit (Read error: Connection reset by peer) 2014-09-20T05:50:58Z Neet__ quit (Read error: Connection reset by peer) 2014-09-20T05:51:02Z dytrivedi_ quit (Ping timeout: 245 seconds) 2014-09-20T05:51:13Z superjudge____ quit (Write error: Connection reset by peer) 2014-09-20T05:51:14Z kwmiebach______ quit (Read error: Connection reset by peer) 2014-09-20T05:51:26Z jcloud quit (Read error: Connection reset by peer) 2014-09-20T05:51:32Z pjdelport quit (Ping timeout: 245 seconds) 2014-09-20T05:51:54Z greghendershott quit (Ping timeout: 272 seconds) 2014-09-20T05:52:21Z ELLIOTTCABLE quit (Ping timeout: 260 seconds) 2014-09-20T05:53:10Z aksatac___ quit (Ping timeout: 272 seconds) 2014-09-20T05:53:12Z ggherdov___ quit (Ping timeout: 260 seconds) 2014-09-20T05:55:04Z common-lisper quit (Remote host closed the connection) 2014-09-20T05:58:22Z common-lisper joined #scheme 2014-09-20T05:58:37Z samth quit (Ping timeout: 272 seconds) 2014-09-20T06:02:33Z emma quit (Ping timeout: 260 seconds) 2014-09-20T06:04:02Z emma joined #scheme 2014-09-20T06:12:58Z jcloud joined #scheme 2014-09-20T06:15:22Z _tca joined #scheme 2014-09-20T06:15:43Z aksatac___ joined #scheme 2014-09-20T06:15:49Z ELLIOTTCABLE_ joined #scheme 2014-09-20T06:15:53Z superjudge____ joined #scheme 2014-09-20T06:16:25Z pjdelport joined #scheme 2014-09-20T06:16:28Z kwmiebach______ joined #scheme 2014-09-20T06:17:59Z greghendershott joined #scheme 2014-09-20T06:18:16Z offby1 joined #scheme 2014-09-20T06:18:20Z omefire1 quit (Read error: Connection reset by peer) 2014-09-20T06:19:30Z kongtomorrow joined #scheme 2014-09-20T06:19:45Z Neet__ joined #scheme 2014-09-20T06:22:14Z ggherdov___ joined #scheme 2014-09-20T06:22:32Z common-lisper quit 2014-09-20T06:23:26Z gluegadget_ joined #scheme 2014-09-20T06:23:46Z pjdelport quit (Quit: Connection closed for inactivity) 2014-09-20T06:24:19Z spaceotter joined #scheme 2014-09-20T06:24:39Z spaceotter quit (Client Quit) 2014-09-20T06:25:26Z dytrivedi_ joined #scheme 2014-09-20T06:25:27Z samth joined #scheme 2014-09-20T06:33:37Z slmult0_z_y_h_g_ quit (Ping timeout: 272 seconds) 2014-09-20T06:34:38Z slmult0_z joined #scheme 2014-09-20T06:39:01Z slmult0_z quit (Ping timeout: 260 seconds) 2014-09-20T06:53:50Z mutley89 joined #scheme 2014-09-20T07:08:32Z bjz joined #scheme 2014-09-20T07:16:10Z suppi joined #scheme 2014-09-20T07:39:29Z suppi quit (Ping timeout: 272 seconds) 2014-09-20T07:49:14Z robot-beethoven quit (Quit: ERC Version 5.3 (IRC client for Emacs)) 2014-09-20T07:49:59Z kongtomorrow quit 2014-09-20T07:54:02Z kongtomorrow joined #scheme 2014-09-20T08:12:00Z tadni` quit (Remote host closed the connection) 2014-09-20T08:13:12Z jcloud quit (Quit: Connection closed for inactivity) 2014-09-20T08:16:26Z lrs_ joined #scheme 2014-09-20T08:20:05Z tadni joined #scheme 2014-09-20T08:20:06Z mercwithamouth joined #scheme 2014-09-20T08:20:49Z tadni quit (Remote host closed the connection) 2014-09-20T08:24:27Z suppi joined #scheme 2014-09-20T08:28:04Z mrowe_away is now known as mrowe 2014-09-20T08:29:04Z DGASAU quit (Ping timeout: 260 seconds) 2014-09-20T08:29:36Z kongtomorrow quit 2014-09-20T08:31:12Z DGASAU joined #scheme 2014-09-20T08:33:13Z vanila: is there any way to do modules in chicken scheme without having the entire file indented? 2014-09-20T08:37:46Z kobain quit (Quit: KVIrc 4.1.3 Equilibrium http://www.kvirc.net/) 2014-09-20T08:38:19Z CaptainRant joined #scheme 2014-09-20T08:39:53Z suppi quit (Ping timeout: 260 seconds) 2014-09-20T08:41:56Z tadni joined #scheme 2014-09-20T08:42:34Z mrowe is now known as mrowe_away 2014-09-20T08:49:20Z stepnem joined #scheme 2014-09-20T09:08:53Z suppi joined #scheme 2014-09-20T09:17:23Z petercommand quit (Ping timeout: 240 seconds) 2014-09-20T09:17:41Z BitPuffin quit (Ping timeout: 260 seconds) 2014-09-20T09:26:02Z vanila quit (Quit: Leaving) 2014-09-20T09:39:21Z taylanub: in R7RS-small I just use `include' to include the library body so the whole thing isn't intended, plus you can include it from other types of module/library declaration syntaxes to make modules/libs for many Scheme implementations. R6RS is notoriously lacking an `include' and the proposed syntax-case using implementation doesn't necessarily handle issues with the working directory vs. the 2014-09-20T09:39:22Z taylanub: directory of the file being evaled so ... R7RS-small library syntax is surprisingly more useful -_- 2014-09-20T09:39:33Z taylanub: s/intended/indented/ 2014-09-20T09:45:09Z vinleod quit (Quit: ["Textual IRC Client: www.textualapp.com"]) 2014-09-20T09:48:46Z oldskirt joined #scheme 2014-09-20T09:50:18Z bjz quit (Quit: Textual IRC Client: www.textualapp.com) 2014-09-20T09:50:32Z bjz joined #scheme 2014-09-20T10:07:11Z mrowe_away is now known as mrowe 2014-09-20T10:14:54Z Nizumzen joined #scheme 2014-09-20T10:14:56Z ijp: or you could just not indent the body 2014-09-20T10:18:21Z bjz quit (Ping timeout: 260 seconds) 2014-09-20T10:19:20Z Cromulent joined #scheme 2014-09-20T10:19:20Z dmiles_afk quit (Read error: Connection reset by peer) 2014-09-20T10:21:46Z bjz joined #scheme 2014-09-20T10:22:33Z Cromulent quit (Client Quit) 2014-09-20T10:22:49Z Nizumzen quit (Ping timeout: 258 seconds) 2014-09-20T10:23:02Z dmiles joined #scheme 2014-09-20T10:25:02Z joneshf quit (Ping timeout: 258 seconds) 2014-09-20T10:25:03Z ecraven quit (Ping timeout: 258 seconds) 2014-09-20T10:26:12Z SHODAN quit (Ping timeout: 258 seconds) 2014-09-20T10:26:21Z Nizumzen joined #scheme 2014-09-20T10:27:15Z Kruppe quit (Ping timeout: 258 seconds) 2014-09-20T10:27:20Z micro_ quit (Ping timeout: 258 seconds) 2014-09-20T10:27:34Z micro joined #scheme 2014-09-20T10:27:41Z joneshf joined #scheme 2014-09-20T10:27:59Z micro is now known as Guest56725 2014-09-20T10:28:03Z taylanub: someone will have to teach Emacs to do that 2014-09-20T10:28:45Z SHODAN joined #scheme 2014-09-20T10:30:03Z taylanub: why's there no call-with-(input|output)-string and with-(input-from|output-to)-string in R7RS and instead only open-(input|output)-string and get-output-string -_- 2014-09-20T10:30:03Z sad0ur_ joined #scheme 2014-09-20T10:30:05Z taylanub: same for bytevectors 2014-09-20T10:31:30Z sad0ur quit (Ping timeout: 258 seconds) 2014-09-20T10:32:54Z mario-go` joined #scheme 2014-09-20T10:34:04Z _5kg_ quit (Remote host closed the connection) 2014-09-20T10:34:38Z mario-goulart quit (Ping timeout: 258 seconds) 2014-09-20T10:36:35Z mrowe is now known as mrowe_away 2014-09-20T10:36:51Z hiroakip joined #scheme 2014-09-20T10:37:14Z Kruppe joined #scheme 2014-09-20T10:38:42Z _5kg joined #scheme 2014-09-20T10:45:59Z Nizumzen quit (Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/) 2014-09-20T10:55:19Z petercommand joined #scheme 2014-09-20T11:03:29Z hiroakip quit (Ping timeout: 272 seconds) 2014-09-20T11:06:02Z jusss joined #scheme 2014-09-20T11:11:25Z mario-go` is now known as mario-goulart 2014-09-20T11:12:14Z circ-user-knElw joined #scheme 2014-09-20T11:14:50Z impaktor left #scheme 2014-09-20T11:16:56Z Nizumzen joined #scheme 2014-09-20T11:17:13Z MouldyOldBones joined #scheme 2014-09-20T11:23:01Z rszeno joined #scheme 2014-09-20T11:34:55Z suppi quit (Ping timeout: 272 seconds) 2014-09-20T11:35:31Z MichaelRaskin quit (Ping timeout: 244 seconds) 2014-09-20T11:43:33Z circ-user-knElw_ joined #scheme 2014-09-20T11:44:17Z circ-user-knElw_ quit (Remote host closed the connection) 2014-09-20T11:45:07Z ijp quit (Quit: goto library;) 2014-09-20T11:46:58Z circ-user-knElw quit (Ping timeout: 272 seconds) 2014-09-20T11:47:22Z acarrico quit (Ping timeout: 240 seconds) 2014-09-20T11:50:24Z bars0 joined #scheme 2014-09-20T11:57:09Z jusss quit (Read error: Connection reset by peer) 2014-09-20T12:01:39Z suppi joined #scheme 2014-09-20T12:03:36Z bars0 quit (Quit: leaving) 2014-09-20T12:04:12Z rszeno quit (Quit: Leaving.) 2014-09-20T12:08:05Z suppi quit (Ping timeout: 272 seconds) 2014-09-20T12:09:26Z klltkr joined #scheme 2014-09-20T12:15:21Z stablerobber joined #scheme 2014-09-20T12:17:43Z jusss joined #scheme 2014-09-20T12:27:13Z civodul joined #scheme 2014-09-20T12:27:34Z davexunit joined #scheme 2014-09-20T12:28:37Z lrs_: How do i create multiplication by only using this : http://pastebin.com/hTWYMenk 2014-09-20T12:30:51Z pjb: lrs_: you need to use more than only those two functions, but a*b = a+a+a…+a (b times). 2014-09-20T12:31:05Z pjb: and a+b = (a+1)+(b-1) and a+0 = a 2014-09-20T12:31:35Z oleo__ quit (Quit: Verlassend) 2014-09-20T12:32:20Z lrs_: pjb: I got this 2014-09-20T12:33:45Z lrs_: pjb http://pastebin.com/GQGbdjza 2014-09-20T12:33:55Z lrs_: And im assuming im gonna rename it 2014-09-20T12:34:03Z lrs_: And change something in the recursive thing 2014-09-20T12:34:20Z pjb: better (plus (pred a) (succ b)) 2014-09-20T12:34:54Z lrs_: Hmm? 2014-09-20T12:35:15Z pjb: So now you have plus, you cam write mult. a*0 = 0, a*1 = a, a*b = a*(1+(b-1)) = a*1+a*(b-1) 2014-09-20T12:35:19Z carc_00 quit (K-Lined) 2014-09-20T12:36:13Z pjb: lrs_: with (plus (pred a) (succ b)) plus is a terminal call, so TCO can be performed. Otherwise, you will use O(b) stack space. 2014-09-20T12:37:17Z lrs_: Im not really sure what that means 2014-09-20T12:37:35Z suppi joined #scheme 2014-09-20T12:38:04Z pjb: trace plus and succ. 2014-09-20T12:40:05Z lrs_: I did 2014-09-20T12:40:21Z lrs_: >(plus 0 3) 2014-09-20T12:40:23Z lrs_: <3 2014-09-20T12:40:23Z lrs_: 3 2014-09-20T12:41:12Z pjb: http://paste.lisp.org/+32YA 2014-09-20T12:41:30Z pjb: plus1 must use the stack to remember it has to call succ at the end. 2014-09-20T12:41:58Z pjb: plus2 can call succ and pred immediately, and can iterate without using the stack, instead of perform a recursive call. 2014-09-20T12:42:17Z oleo joined #scheme 2014-09-20T12:44:24Z klltkr quit (Quit: My MacBook has gone to sleep. ZZZzzz…) 2014-09-20T12:44:46Z klltkr joined #scheme 2014-09-20T12:45:05Z klltkr quit (Client Quit) 2014-09-20T12:51:44Z davexunit quit (Quit: Later) 2014-09-20T12:51:45Z lrs_: pjb, Whats a stack? 2014-09-20T12:52:44Z oleo is now known as Guest16743 2014-09-20T12:54:20Z oleo__ joined #scheme 2014-09-20T12:54:30Z pjb: A stack is a data structure that has the following operations: new-stack, push, pop such as: (empty-stack) --> stack ; (push e stack) -> stack' ; (pop (push e stack)) == e 2014-09-20T12:54:54Z alexei___ quit (Ping timeout: 272 seconds) 2014-09-20T12:55:49Z stablerobber is now known as prickler 2014-09-20T12:56:00Z Guest16743 quit (Ping timeout: 260 seconds) 2014-09-20T12:56:46Z pjb: When a function f calls a function g, it saves on the stack all its local state, and it pushes the arguments to the function g. This allows for recursive calls: when g calls f, it pushes its own state and the arguments to f on the stack, etc. 2014-09-20T12:57:01Z prickler is now known as stillroof 2014-09-20T12:57:33Z lrs_: All the local states of the function g? 2014-09-20T12:57:37Z pjb: Yes. 2014-09-20T12:57:58Z lrs_: This stuff is kind of hard to visualize 2014-09-20T12:58:04Z lrs_: I just started this course 2014-09-20T12:58:25Z pjb: Actually it's very easy. https://www.google.com/search?q=function+call+stack&newwindow=1&safe=off&client=iceweasel-a&rls=org.mozilla:en-US:unofficial&tbm=isch&tbo=u&source=univ&sa=X&ei=5XkdVNiHNYraasXmgpgE&ved=0CC4QsAQ&biw=880&bih=855 2014-09-20T12:58:25Z rudybot: http://tinyurl.com/krxuc4t 2014-09-20T12:58:50Z pjb: http://www.installsetupconfig.com/win32programming/processtoolhelpapis12_files/winprocesstoolhelpapiscode003.png 2014-09-20T12:58:50Z rudybot: http://tinyurl.com/lj7ys2c 2014-09-20T12:59:21Z pjb: It's all good, until you start to have very deep recursions. 2014-09-20T12:59:40Z pjb: Each thread has its own stack, usually of relatively limited space (about 1 or 2 MB). 2014-09-20T13:00:16Z pjb: Since the stack may contain pointers, it's hard to move it in the memory, so it is difficult to extend it beyond the pre-allocated limit. 2014-09-20T13:01:05Z pjb: Therefore when you have deep recursions, you can easily reach the limit for the stack space, and get out-of-stack-space errors (or in general, SIGSEGV). 2014-09-20T13:01:12Z oleo__ quit (Quit: Verlassend) 2014-09-20T13:02:17Z kazimir42 quit (Remote host closed the connection) 2014-09-20T13:03:41Z pjb: So if the function f calls the function g as the last thing it does, that is, when the call to g is a tail call, the space used on the stack by the function f is not needed anymore. And there's no need to save the state of f, since calling g is the last thing it does, and when g returns, f will returns immediately too. 2014-09-20T13:04:09Z oleo__ joined #scheme 2014-09-20T13:04:32Z oleo__ is now known as oleo 2014-09-20T13:04:42Z pjb: Therefore tail calls can be optimized, by poping the space used by the current function from the stack, pushin the arguments, and _jumping_ to g, instead of calling it. 2014-09-20T13:05:13Z pjb: If g = f, then pushing the arguments = assign the new values to the arguments, and jumping is a loop. 2014-09-20T13:05:30Z pjb: So recursive tail calls can be implemented as a mere iteration. 2014-09-20T13:05:38Z pjb: Without using stack space. 2014-09-20T13:07:31Z CaptainRant quit (Quit: WeeChat 0.4.3) 2014-09-20T13:15:24Z emma quit (Ping timeout: 246 seconds) 2014-09-20T13:21:33Z MichaelRaskin joined #scheme 2014-09-20T13:24:29Z jusss quit (Quit: ERC Version 5.2 (IRC client for Emacs)) 2014-09-20T13:24:41Z Nizumzen quit (Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/) 2014-09-20T13:30:09Z emma joined #scheme 2014-09-20T13:41:07Z taylanub quit (Disconnected by services) 2014-09-20T13:41:49Z taylanub joined #scheme 2014-09-20T13:48:25Z ARM9 joined #scheme 2014-09-20T14:07:07Z ijp joined #scheme 2014-09-20T14:13:33Z civodul quit (Quit: ERC Version 5.3 (IRC client for Emacs)) 2014-09-20T14:24:47Z jlongster joined #scheme 2014-09-20T14:24:52Z suppi quit (Ping timeout: 240 seconds) 2014-09-20T14:28:07Z Riastradh joined #scheme 2014-09-20T14:28:51Z suppi joined #scheme 2014-09-20T14:29:36Z jlongster quit (Ping timeout: 258 seconds) 2014-09-20T14:30:34Z ijp quit (Quit: This ijp has ended peacefully) 2014-09-20T14:32:31Z jlongster joined #scheme 2014-09-20T14:34:05Z ijp joined #scheme 2014-09-20T14:38:07Z jlongster quit (Ping timeout: 245 seconds) 2014-09-20T14:45:03Z davexunit joined #scheme 2014-09-20T14:47:39Z Riastradh quit (Ping timeout: 264 seconds) 2014-09-20T14:48:43Z logand joined #scheme 2014-09-20T14:57:57Z emma quit (Ping timeout: 246 seconds) 2014-09-20T14:58:17Z jlongster joined #scheme 2014-09-20T15:07:24Z jlongster quit (Ping timeout: 246 seconds) 2014-09-20T15:08:15Z tobik quit (Read error: Connection reset by peer) 2014-09-20T15:08:29Z tcsc joined #scheme 2014-09-20T15:08:58Z tobik joined #scheme 2014-09-20T15:10:03Z tobik quit (Client Quit) 2014-09-20T15:13:39Z tobik joined #scheme 2014-09-20T15:15:41Z theseb joined #scheme 2014-09-20T15:18:46Z suppi quit (Remote host closed the connection) 2014-09-20T15:20:31Z emma joined #scheme 2014-09-20T15:20:49Z klltkr joined #scheme 2014-09-20T15:35:26Z atomx joined #scheme 2014-09-20T15:35:51Z vanila joined #scheme 2014-09-20T15:37:27Z atomx quit (Remote host closed the connection) 2014-09-20T15:38:04Z atomx joined #scheme 2014-09-20T15:40:55Z atomx quit (Remote host closed the connection) 2014-09-20T15:41:51Z atomx joined #scheme 2014-09-20T15:49:46Z atomx quit (Read error: Connection reset by peer) 2014-09-20T15:56:14Z atomx joined #scheme 2014-09-20T15:57:42Z atomx quit (Read error: Connection reset by peer) 2014-09-20T16:00:01Z jlongster joined #scheme 2014-09-20T16:02:16Z pera joined #scheme 2014-09-20T16:03:58Z kazimir42 joined #scheme 2014-09-20T16:04:44Z CaptainRant joined #scheme 2014-09-20T16:04:57Z jlongster quit (Ping timeout: 272 seconds) 2014-09-20T16:08:39Z CaptainRant: Why is start-thread! postfixed with a ! ? Does it mutate the state more than io functions ? 2014-09-20T16:08:59Z CaptainRant: Or only because other threads might use set! on global identifier ? 2014-09-20T16:13:39Z Nizumzen joined #scheme 2014-09-20T16:14:32Z uselpa joined #scheme 2014-09-20T16:20:50Z stillroof quit (Read error: Connection reset by peer) 2014-09-20T16:23:44Z szgyg joined #scheme 2014-09-20T16:30:37Z tcsc quit (Quit: computer sleeping) 2014-09-20T16:39:44Z tobik quit (Ping timeout: 272 seconds) 2014-09-20T16:41:39Z tobik joined #scheme 2014-09-20T16:43:11Z uselpa quit (Quit: Leaving...) 2014-09-20T16:57:33Z theseb quit (Quit: Leaving) 2014-09-20T16:58:29Z hiroakip joined #scheme 2014-09-20T17:00:43Z jlongster joined #scheme 2014-09-20T17:05:14Z jlongster quit (Ping timeout: 258 seconds) 2014-09-20T17:18:49Z hiroakip quit (Ping timeout: 260 seconds) 2014-09-20T17:19:16Z taylanub: CaptainRant: there is not standard procedure `start-thread!'. Starting a thread can be seen as mutating global state though 2014-09-20T17:20:28Z hiroakip joined #scheme 2014-09-20T17:21:24Z daviid joined #scheme 2014-09-20T17:22:25Z uselpa joined #scheme 2014-09-20T17:29:07Z pjdelport joined #scheme 2014-09-20T17:29:56Z hiroakip quit (Ping timeout: 260 seconds) 2014-09-20T17:30:48Z uselpa quit (Quit: Leaving...) 2014-09-20T17:32:44Z taylanub: hm, it would be really neat if those SRFIs for which it's possible would get R7RS-small implementations 2014-09-20T17:40:13Z DKordic joined #scheme 2014-09-20T17:40:14Z Nizumzen quit (Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/) 2014-09-20T17:49:08Z asumu quit (Changing host) 2014-09-20T17:49:08Z asumu joined #scheme 2014-09-20T17:56:53Z duncanm quit (Ping timeout: 240 seconds) 2014-09-20T17:57:47Z lrs_: http://pastebin.com/pVL3zYNL I need to define this function for creating a function that does a factorial of a number by using pred 2014-09-20T17:57:57Z lrs_: But when I replace - n 1 with pred it doesnt work... Why? 2014-09-20T17:58:16Z vanila: replace (- n 1) with (pred n) ? 2014-09-20T17:59:45Z jlongster joined #scheme 2014-09-20T18:01:38Z vanila: https://www.youtube.com/watch?v=RG9fBbQrVOMa 2014-09-20T18:04:09Z jlongster quit (Ping timeout: 246 seconds) 2014-09-20T18:05:07Z mark_wea` joined #scheme 2014-09-20T18:06:24Z mark_weaver quit (Read error: Connection reset by peer) 2014-09-20T18:13:39Z duncanm joined #scheme 2014-09-20T18:13:39Z rudybot: la la la 2014-09-20T18:15:02Z alexei___ joined #scheme 2014-09-20T18:21:50Z kobain joined #scheme 2014-09-20T18:23:05Z kobain quit (Max SendQ exceeded) 2014-09-20T18:24:32Z kobain joined #scheme 2014-09-20T18:38:20Z jlongster joined #scheme 2014-09-20T18:51:20Z ilammy joined #scheme 2014-09-20T18:54:33Z zlrth quit (Ping timeout: 246 seconds) 2014-09-20T18:56:52Z gluegadget_ is now known as gluegadget 2014-09-20T18:56:55Z gluegadget quit (Changing host) 2014-09-20T18:56:55Z gluegadget joined #scheme 2014-09-20T18:56:55Z gluegadget quit (Changing host) 2014-09-20T18:56:55Z gluegadget joined #scheme 2014-09-20T19:15:54Z mark_wea` is now known as mark_weaver 2014-09-20T19:19:03Z mutley89 quit (Ping timeout: 246 seconds) 2014-09-20T19:20:40Z Nizumzen joined #scheme 2014-09-20T19:27:27Z atomx_ quit (Ping timeout: 246 seconds) 2014-09-20T19:32:12Z duncanm quit (Ping timeout: 260 seconds) 2014-09-20T19:33:32Z lrs_ quit (Ping timeout: 245 seconds) 2014-09-20T19:34:41Z duncanm joined #scheme 2014-09-20T19:34:41Z rudybot: la la la 2014-09-20T19:35:37Z ilammy: gununu 2014-09-20T19:37:13Z oleo: huehuehue 2014-09-20T19:37:52Z duncanm quit (Remote host closed the connection) 2014-09-20T19:39:11Z vanila left #scheme 2014-09-20T19:40:19Z atomx joined #scheme 2014-09-20T19:44:10Z duncanm joined #scheme 2014-09-20T19:44:10Z rudybot: la la la 2014-09-20T19:45:53Z atomx_ joined #scheme 2014-09-20T19:53:14Z atomx quit (Remote host closed the connection) 2014-09-20T19:53:51Z atomx_ quit (Remote host closed the connection) 2014-09-20T19:54:10Z atomx joined #scheme 2014-09-20T20:02:57Z Nizumzen quit (Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/) 2014-09-20T20:04:29Z jlongster quit (Ping timeout: 260 seconds) 2014-09-20T20:06:47Z vukcrni joined #scheme 2014-09-20T20:08:34Z tcsc joined #scheme 2014-09-20T20:11:06Z mrowe_away is now known as mrowe 2014-09-20T20:11:18Z tcsc quit (Client Quit) 2014-09-20T20:12:35Z mercwithamouth quit (Ping timeout: 272 seconds) 2014-09-20T20:17:53Z jeapostrophe joined #scheme 2014-09-20T20:21:33Z anannie quit (Quit: No Ping reply in 180 seconds.) 2014-09-20T20:21:51Z anannie joined #scheme 2014-09-20T20:27:57Z nisstyre quit (Quit: WeeChat 1.0) 2014-09-20T20:28:13Z nisstyre joined #scheme 2014-09-20T20:28:34Z nisstyre quit (Client Quit) 2014-09-20T20:29:53Z klltkr quit (Quit: My MacBook has gone to sleep. ZZZzzz…) 2014-09-20T20:30:33Z ARM9 quit (Quit: Leaving) 2014-09-20T20:31:52Z jeapostrophe quit (Ping timeout: 240 seconds) 2014-09-20T20:35:48Z szgyg quit (Quit: leaving) 2014-09-20T20:36:52Z mornfall quit (Ping timeout: 245 seconds) 2014-09-20T20:39:01Z duncanm quit (Ping timeout: 260 seconds) 2014-09-20T20:39:42Z duncanm joined #scheme 2014-09-20T20:39:42Z rudybot: la la la 2014-09-20T20:40:01Z klltkr joined #scheme 2014-09-20T20:40:16Z mornfall joined #scheme 2014-09-20T20:40:22Z mrowe is now known as mrowe_away 2014-09-20T20:40:27Z mrowe_away is now known as mrowe 2014-09-20T20:45:10Z atomikkk joined #scheme 2014-09-20T20:46:00Z atomikkk: wow sicp is cool sofar, I feel smarter just reading it 2014-09-20T20:49:40Z yacks quit (Ping timeout: 260 seconds) 2014-09-20T20:50:13Z duncanm quit (Ping timeout: 260 seconds) 2014-09-20T20:52:33Z emma quit (Ping timeout: 260 seconds) 2014-09-20T20:53:20Z yacks joined #scheme 2014-09-20T20:54:20Z emma joined #scheme 2014-09-20T21:02:18Z effy_ quit (Ping timeout: 246 seconds) 2014-09-20T21:02:52Z eli joined #scheme 2014-09-20T21:04:55Z mrowe is now known as mrowe_away 2014-09-20T21:13:21Z CaptainRant: Is there a better scheme syntax file for Vim ? Some correct identifier are highlighted as errors, and indention works not always. 2014-09-20T21:13:34Z duncanm joined #scheme 2014-09-20T21:13:34Z rudybot: la la la 2014-09-20T21:15:39Z atomikkk is now known as van-rijn 2014-09-20T21:17:55Z davexunit quit (Quit: Later) 2014-09-20T21:19:02Z emma quit (Ping timeout: 245 seconds) 2014-09-20T21:20:34Z emma joined #scheme 2014-09-20T21:20:42Z emma quit (Changing host) 2014-09-20T21:20:42Z emma joined #scheme 2014-09-20T21:23:03Z kazimir42 quit (Ping timeout: 264 seconds) 2014-09-20T21:29:16Z van-rijn: scheme mode in vim? 2014-09-20T21:29:23Z van-rijn: I think it works well.. 2014-09-20T21:34:20Z kobain quit (Quit: KVIrc 4.1.3 Equilibrium http://www.kvirc.net/) 2014-09-20T21:36:35Z peterhil` quit (Quit: Must not waste too much time here...) 2014-09-20T21:38:28Z van-rijn: http://endthefed.livejournal.com/ 2014-09-20T21:51:16Z kongtomorrow joined #scheme 2014-09-20T21:51:29Z van-rijn quit (Remote host closed the connection) 2014-09-20T21:51:32Z kongtomorrow quit (Client Quit) 2014-09-20T21:52:03Z kongtomorrow joined #scheme 2014-09-20T21:52:57Z tcsc joined #scheme 2014-09-20T21:53:01Z tcsc quit (Remote host closed the connection) 2014-09-20T21:54:54Z oldskirt quit (Quit: gone) 2014-09-20T21:55:08Z kongtomorrow quit (Client Quit) 2014-09-20T21:56:34Z kobain joined #scheme 2014-09-20T21:57:49Z kobain quit (Max SendQ exceeded) 2014-09-20T21:59:16Z kobain joined #scheme 2014-09-20T22:06:22Z ehaliewicz joined #scheme 2014-09-20T22:11:03Z Rodya_ joined #scheme 2014-09-20T22:14:45Z hiyosi quit (Ping timeout: 246 seconds) 2014-09-20T22:19:18Z dmiles quit (Read error: Connection reset by peer) 2014-09-20T22:20:06Z dmiles_afk joined #scheme 2014-09-20T22:38:40Z kongtomorrow joined #scheme 2014-09-20T22:40:08Z oldskirt joined #scheme 2014-09-20T22:41:33Z hiyosi joined #scheme 2014-09-20T22:43:04Z bobbinnumerous joined #scheme 2014-09-20T22:44:33Z ctlM joined #scheme 2014-09-20T22:46:27Z hiyosi quit (Ping timeout: 272 seconds) 2014-09-20T22:51:04Z robot-beethoven joined #scheme 2014-09-20T22:54:36Z zlrth joined #scheme 2014-09-20T22:55:22Z ilammy quit (Ping timeout: 246 seconds) 2014-09-20T23:05:00Z kongtomorrow quit (Ping timeout: 260 seconds) 2014-09-20T23:06:01Z ctlM quit (Remote host closed the connection) 2014-09-20T23:06:54Z c107 joined #scheme 2014-09-20T23:07:15Z ijp: lol, gavino has a livejournal 2014-09-20T23:09:03Z kongtomorrow joined #scheme 2014-09-20T23:09:52Z c107: ijp: What's funny about that? 2014-09-20T23:10:59Z ijp: it's just really apt 2014-09-20T23:17:12Z acarrico joined #scheme 2014-09-20T23:20:25Z c107: ijp: apt sucks 2014-09-20T23:20:52Z duncanm quit (Ping timeout: 260 seconds) 2014-09-20T23:21:12Z davexunit joined #scheme 2014-09-20T23:21:32Z duncanm joined #scheme 2014-09-20T23:21:32Z rudybot: la la la 2014-09-20T23:24:51Z jlongster joined #scheme 2014-09-20T23:29:56Z c107: ,(+ 1 11) 2014-09-20T23:29:57Z ctlM joined #scheme 2014-09-20T23:33:01Z alexei___ quit (Ping timeout: 260 seconds) 2014-09-20T23:34:33Z ctlM quit (Remote host closed the connection) 2014-09-20T23:34:54Z c107 quit (Ping timeout: 246 seconds) 2014-09-20T23:35:25Z ctlM joined #scheme 2014-09-20T23:36:35Z ctlM is now known as cgrid24 2014-09-20T23:37:30Z cgrid24 quit (Remote host closed the connection) 2014-09-20T23:38:57Z stepnem quit (Ping timeout: 245 seconds) 2014-09-20T23:39:33Z duncanm quit (Ping timeout: 260 seconds) 2014-09-20T23:42:32Z hiyosi joined #scheme 2014-09-20T23:43:40Z eupcan277 joined #scheme 2014-09-20T23:43:52Z eupcan277 quit (Read error: error:1408F119:SSL routines:SSL3_GET_RECORD:decryption failed or bad record mac) 2014-09-20T23:47:09Z hiyosi quit (Ping timeout: 246 seconds) 2014-09-20T23:47:16Z eupcan277 joined #scheme 2014-09-20T23:47:28Z oldskirt quit (Ping timeout: 260 seconds) 2014-09-20T23:51:40Z duncanm joined #scheme 2014-09-20T23:51:40Z rudybot: la la la 2014-09-20T23:58:04Z BitPuffin joined #scheme