←2007-05-24 2007-05-25 2007-05-26→ ↑2007 ↑all
00:15:26 <ehird`> hmm
00:15:31 <ehird`> i don't even have to implement scoping
00:15:47 <ehird`> no nested "operator functions" (non-[lambda]-pushed-to-stack functions that is)
00:15:51 <ehird`> just a hash table
00:16:44 <ihope> I smell evil.
00:17:09 <ehird`> no - just a stack-based, functional language
00:17:13 <ehird`> so - evil
00:17:54 <ihope> Egad... actually, yes, that is evil.
00:19:03 <ehird`> factorial = dup 1 > [dup 1 - factorial *] [pop 1] if ;;
00:19:03 <ehird`> :)
00:19:22 <SimonRC> ehird`: no
00:19:29 <ehird`> SimonRC: no what
00:19:35 <ihope> Wait, no monads?
00:19:36 <ihope> Evil.
00:19:39 <SimonRC> I think this wuold look better:
00:19:52 <SimonRC> [dup 1 > [dup 1 - factorial *] [pop 1] if] "factorial" define
00:19:52 <ehird`> ihope: monads? pah! real functional programmers MANUALLY APPLY IO
00:20:06 <SimonRC> actually, monads would be handy in Factor
00:20:09 <ehird`> OK, so they get their runtime system to do it for them, but...
00:20:21 <SimonRC> they reduce the amount of crap that you need to shuffle around on the stack
00:20:21 <ehird`> SimonRC: well - [lambda] forms aren't implicitly called
00:20:23 <ihope> Manually as in... like, how?
00:20:32 <SimonRC> ehird`: yes, that's my point
00:20:37 <ehird`> 2 [dup] --> 2 [dup], instead of 2 [dup] -> 2 2
00:20:42 <ehird`> "call" evaluates them
00:20:45 <ehird`> 2 [dup] call --> 2 2
00:20:50 <SimonRC> yes, i konw
00:21:01 <SimonRC> my example depends on that
00:21:05 <ehird`> hrm
00:21:09 <lament> looks boring
00:21:10 <ehird`> OK.. but I like the ;;
00:21:22 <ehird`> it's ocamlish :P
00:21:25 <lament> doesn't Joy do that?
00:21:32 <ehird`> lament: joy uses .
00:21:32 <ihope> Real functional programmers do impureness?
00:21:33 <ehird`> plus it's less ugly with multiple lines:
00:21:37 <SimonRC> I push a block that is the definition of factorial, then a string that is the name of factorial, then I call "define"
00:21:41 * ehird` pasted http://pastie.textmate.org/64416
00:22:43 <SimonRC> yeah
00:22:54 <SimonRC> I find my way more elegant
00:23:35 <SimonRC> because then "define" becomes equal to: get-current-scope's-hashtable set
00:23:54 <ehird`> scopes? this is a stack-based language ;)
00:24:03 <ehird`> the only scope i need is the global scope to store self-evaluating functions
00:24:11 <SimonRC> so you can start defining your own definition operators, like ones that do overloading
00:24:44 <SimonRC> they would just add a method the list of methods for a certain generic function
00:25:19 <SimonRC> argh! bed-time.
00:25:43 <ehird`> hehe
00:26:00 <ehird`> i wonder if i'll be able to handle reverse-polishness to actually write some programs in the language
00:26:17 <ehird`> ... probably. i can do some forth.
00:44:46 -!- Aoshi has joined.
00:44:55 -!- Aoshi has left (?).
00:46:16 <ehird`> well that parser wasn't hard
00:46:23 <ehird`> just have to make it convert X = Y ;; to a hashtable {X => Y}
00:56:41 <ehird`> .... which is the hardest part
01:00:54 <ehird`> it works
01:00:56 <ehird`> yippee
01:30:05 -!- ehird` has quit.
02:54:08 -!- ihope has quit (Read error: 110 (Connection timed out)).
03:18:16 -!- ihope has joined.
03:25:43 -!- SuperAussieEvil has joined.
03:25:58 <SuperAussieEvil> Hi
03:26:49 <ihope> Hello, above Australian self-serving-at-the-expense-of-others!
03:27:25 <SuperAussieEvil> ?
03:28:06 <ihope> "Super" = "above", "Aussie" = "Australian" and "Evil" =
03:28:09 <ihope> "self-serving-at-the-expense-of-others", correct?
03:44:25 <SuperAussieEvil> ...uh
03:50:54 <bsmntbombdood> heh
03:51:06 <SuperAussieEvil> Synonyms do not flatter
03:52:07 <ihope> I suppose that's true.
03:52:11 <SuperAussieEvil> NOSES ARE A WASTE OF BANDWIDTH!
03:52:35 <ihope> Is the horizontal line going through the nostrils called the band?
03:52:37 <ihope> :-P
03:55:29 <SuperAussieEvil> AAH!
03:55:37 * SuperAussieEvil head bleeds
03:55:41 <Pikhq> ^ム^
03:56:11 * bsmntbombdood doesn't understand unicode
03:56:57 <Pikhq> It's a smilie.
03:58:08 <ihope> ン is also a smilie.
03:58:13 <ihope> It's just not a very good one.
03:59:11 <Pikhq> そっ。
03:59:30 <ihope> I really need to learn what そ is.
03:59:37 <ihope> And っ too, for that matter.
03:59:39 <Pikhq> I'm agreeing, that's all.
03:59:53 <Pikhq> 日本語で話せるか。
04:00:07 <ihope>
04:00:15 <Pikhq> XD
04:00:22 <ihope> Hmm. That's like っ, only bigger.
04:00:42 <Pikhq> Yeah.
04:00:47 <ihope> And it's tsu.
04:00:49 <Pikhq> "tu" versus "xtu".
04:01:03 <ihope> Ah! そ is so.
04:01:12 <Pikhq> http://en.wikipedia.org/wiki/%E3%81%A3
04:01:14 <Pikhq> Yeah.
04:01:25 <ihope> So, uh, so and a little tsu.
04:01:44 <ihope> Would that be tso, by any chance?
04:02:03 <ihope> Oh, that page details it.
04:02:24 <ihope> In katakana, it's a smile! ツ
04:03:19 <Pikhq> へムへ
04:03:34 <ihope> So is that sort of a "so--"?
04:04:04 <Pikhq> Just using "so" as an interjection.
04:05:00 <ihope> Looks like glottal stop to me.
04:05:48 <Pikhq> It's also used at the end of interjections.
04:17:35 <SuperAussieEvil> NOSES ARE A WASTE OF BANDWIDTH!
04:38:19 -!- SuperAussieEvil has quit ("Leaving").
05:03:09 <bsmntbombdood> what's an algorithm that takes more memory to compute than it takes to verify?
05:05:30 <bsmntbombdood> NP for memory
05:13:59 -!- ihope has quit (Read error: 60 (Operation timed out)).
07:59:59 -!- clog has quit (ended).
08:00:00 -!- clog has joined.
08:04:32 -!- oerjan has joined.
08:20:45 <oerjan> bsmntbombdood: An algorithm cannot take much more memory to compute than to verify, because any verification can be turned into a search algorithm
08:21:02 <bsmntbombdood> oerjan: yeah, figured that out
08:22:01 <oerjan> space complexity is strange that way. are you aware of the NSPACE <= squared SPACE result?
08:22:39 <bsmntbombdood> but you can make the codomain large enough to make brute force impractical
08:24:12 <oerjan> Savitch's theorem was the name
08:24:27 <bsmntbombdood> i'm looking for something with polynomial space verification, exponential space computation and exponential time brute forcing
08:26:14 <oerjan> and how does savitch's theorem not prove that impossible?
08:26:35 <bsmntbombdood> i don't know
08:26:39 <oerjan> http://en.wikipedia.org/wiki/Savitch%27s_theorem
08:27:08 <bsmntbombdood> squared space computation would be better than nothing
08:28:10 <oerjan> well, graph reachability (STCON in the article) contains essentially the whole difference
08:29:37 <oerjan> of course like with P=NP there is no known proof that there really is a square difference.
08:37:58 <bsmntbombdood> i'm going to bed
08:39:34 <oerjan> good night
08:54:26 -!- oerjan has quit ("leaving").
09:37:48 -!- GregorR has quit (Remote closed the connection).
09:52:36 <oklopol> そっ。 little girl defecating while committing fellatio?
11:01:27 -!- ptitz has joined.
11:02:58 -!- ptitz has left (?).
12:10:16 -!- venkatesh has joined.
12:26:24 <SimonRC> oklopol: ?!
13:07:24 -!- jix__ has joined.
13:26:07 -!- venkatesh has left (?).
13:54:08 -!- jix__ has quit (Read error: 110 (Connection timed out)).
13:54:39 -!- jix__ has joined.
14:27:56 -!- helios24_ has quit (Read error: 110 (Connection timed out)).
14:45:31 -!- helios24 has joined.
15:20:06 <oklopol> i asked if it was an emoticon for that
15:21:01 <Pikhq> Nope.
15:21:05 <Pikhq> It's a *word*.
15:43:19 <oklopol> yeah, right.
15:44:07 <oklopol> hope you ppl are all here for esoteric _programming_
16:35:32 <Pikhq> でもエステリック語はたのしすぎる、よ。
16:35:49 <Pikhq> (but esoteric spoken languages are too much fun.)
16:37:25 <oklopol> guess so :\
16:37:27 <oklopol> japanese?
16:37:57 <oklopol> my friends are anime freaks, would be cool to own them in japanese
16:38:34 <Pikhq> Ah, otaku. What fun it is to mess with them. . .
16:39:19 <Pikhq> Sometimes, you don't even need to know more Japanese than what it takes to tell the difference between hiragana, katakana, and kanji to be effective.
16:40:20 <oklopol> mmm why?
16:40:34 <oklopol> i never remember even those
16:40:42 <oklopol> heard them a million times
16:40:46 <oklopol> one or two though
16:41:02 <Pikhq> Because sometimes otaku will have a shirt saying, say, "オタク" instead of "おたく".
16:41:35 <Pikhq> (katakana should be used for onomatopeia, foreign words, and occasionally for emphasis. Hiragana and kanji are normal for native words)
16:43:05 <SimonRC> gah
16:51:53 <Pikhq> Hmm?
16:56:39 <oklopol> i don't see the point in that but good for otaku i guess
16:56:57 <oklopol> i mean i don't know what you meant
16:57:30 <oklopol> slepation ------>
16:57:31 -!- ihope has joined.
17:06:19 -!- sebbu has joined.
17:31:55 <Pikhq> The point being that that's basic knowledge that otaku lack.
17:39:13 <lament> japanese is an esoteric language now?
17:39:46 <lament> i thought it was one of the major lanugages of the world...
17:40:00 <ihope> Is there any context to lament's question that I need to read the logs to see?
17:40:38 <ihope> Yeah, I guess so.
17:43:27 <ihope> And I better get learning some actual Japanese.
17:44:07 <ihope> I can still say 猫はパンです just fine.
17:44:43 <ihope> パン is katakana, which is a little weird.
17:45:40 <ihope> And ノテンゴイデア, even though that's not actually Japanese.
17:50:32 <Pikhq> You can say that you are bread?
17:51:11 <Pikhq> And, BTW, パン is a loan word from Portuguese.
17:53:42 <lament> all those characters show up as squares :)
17:53:59 <lament> if they really were squares, it would certainly be a very esoteric language.
17:57:47 <ihope> So it's no coincidence that the roumaji for that is "pan", which is the same as the Spanish word for "bread".
17:58:05 <ihope> lament: you're not Japanese enough, then.
17:58:12 <ihope> Isn't 猫 cat?
17:58:35 <ihope> "Are you looking for Unicode character U+732B: cat?"
17:59:23 <Pikhq> Oh, right.
17:59:25 <ihope> Ooh, kJapaneseKun.
17:59:30 <Pikhq> So, you're saying that your *cat* is bread.
17:59:51 <ihope> Is it necessarily my cat?
18:00:09 <ihope> That's "neko wa pan desu", isn't it?
18:00:11 <Pikhq> . . . No.
18:00:22 <ihope> No it isn't necessarily mine?
18:02:02 <Pikhq> Not necessarily.
18:02:25 <Pikhq> 僕は日本語をわすれていると思う。
18:03:53 <ihope> Ooh, more kanji.
18:06:44 -!- oerjan has joined.
18:08:50 <lament> <<*(&>*(<>&(*<>&<>)(*<>
18:08:55 <lament> *(<&{#($*<>({({&<>P *(&
18:08:58 <lament> thank you.
18:09:00 <ihope> Convenient roumaji thingy tells me that's "boku ha nihongo o wasure te iru to omou."
18:09:14 <ihope> Of course, that "ha" is probably actually "wa".
18:09:32 <ihope> And of those, I only know what "wa" means.
18:09:55 <Pikhq> "I think I'm forgetting my Japanese".
18:12:30 <ihope> Hmm.
18:12:37 * ihope throws it at a nearby bd_
18:30:08 * SimonRC has dinner
19:01:49 -!- GregorR has joined.
19:03:22 -!- GregorR has quit (Client Quit).
19:04:36 -!- GregorR has joined.
19:04:44 -!- GregorR has quit (Read error: 104 (Connection reset by peer)).
19:37:18 <SimonRC> hm
19:58:05 <ihope> Indeed, GregorR's being transient again.
19:58:12 <ihope> Stop being so transient, GregorR!
19:58:47 -!- jix__ has changed nick to jix.
20:02:01 -!- mtve has quit (Read error: 110 (Connection timed out)).
20:17:55 -!- GregorR has joined.
20:31:17 <ihope> GregorR: why the transience?
20:47:17 <oerjan> From our birthday, until we die, // Is but the winking of an eye....
21:03:20 -!- sebbu2 has joined.
21:22:13 -!- sebbu has quit (Read error: 110 (Connection timed out)).
21:23:30 <Pikhq> Gregor, why the Plof errors on stdout instead of stderr?
21:41:06 -!- sebbu has joined.
21:46:14 -!- sebbu2 has quit (Read error: 110 (Connection timed out)).
22:18:19 -!- oerjan has quit ("leaving").
22:44:33 -!- ehird` has joined.
23:10:56 * ehird` wonders why 99bob is doing 99->-98
23:15:34 <ehird`> => = dup dup > == or ;;
23:18:48 <oklopol> really?
23:18:51 <oklopol> how come?
23:19:20 <oklopol> if that was an equation over =
23:23:26 * ehird` pasted http://pastie.textmate.org/64693
23:23:28 <ehird`> that's the 99bob program
23:23:34 * ehird` pasted http://pastie.textmate.org/64694
23:23:49 <ehird`> this is what => etc are defined as
23:23:52 <ehird`> the rest is pretty obvious
23:23:54 <ehird`> it currently tries to pop from an empty stack in swap
23:23:57 <ehird`> L/
23:23:58 <ehird`> *:/
23:26:34 <oklopol> dup dup > == or ;; ==== dup 0 == or ;; ==== (lambda a,b : a or not b), or?
23:26:49 <ehird`> err
23:26:54 <ehird`> it works like this:
23:26:57 <oklopol> hmm
23:27:00 <ehird`> true false
23:27:03 <ehird`> false true (swapped)
23:27:04 <oklopol> mine was wrong
23:27:13 <ehird`> (false is...false, so run pop) true
23:27:17 <ehird`> or::::
23:27:19 <ehird`> false true
23:27:22 <ehird`> true false (swapped)
23:27:27 <ehird`> (true is true, so swap) false true
23:27:29 <ehird`> (and pop) true
23:27:35 <ehird`> [] is a lambda
23:27:56 <oklopol> dup dup > == or ;; works like that?
23:27:57 <ehird`> if pops off IFFALSE, IFTRUE, and COND... you can guess the rest
23:28:10 <ehird`> oklopol: > pops twice and replaces it with true or false
23:28:14 <ehird`> == does the same
23:28:26 <ehird`> so you might have true false (>, not ==) or false true (==, not >)
23:28:38 <ehird`> =>, of course, is eq-or-gt
23:29:21 <oklopol> hmm
23:29:29 <oklopol> why does the swap coma along?
23:29:33 <oklopol> *come
23:30:02 <ehird`> well, visualize what or does with the stacks [true, false], [false, true], [false, false] and [true, true] in your head, using these stack signatures:
23:30:09 <ehird`> swap = a b -> b a
23:30:14 <ehird`> pop = a b -> a
23:30:30 <ehird`> if = c t f = result of calling t if c, else result of calling f
23:30:34 <oklopol> okay... now where is there a swap or a pop?
23:30:36 <oklopol> or if?
23:30:45 <ehird`> well - in the core implementation
23:30:49 <ehird`> its not hard to figure out what they do
23:30:51 <oklopol> i can't see it in "dup dup > == or ;;"
23:30:53 <oklopol> oh
23:30:59 <ehird`> or = swap [swap pop] [pop] if ;;
23:31:02 <ehird`> i pasted that
23:31:05 <oklopol> you mean the source?
23:31:07 <ehird`> yes
23:31:15 <ehird`> it isn't self-hosting ;;)
23:33:25 -!- calamari has joined.
23:34:09 <oklopol> ah i guessed if wrong
23:34:13 <oklopol> 'if'
23:34:25 <oklopol> got it now
23:34:29 <ehird`> C T F if => is C true? if so, call T, otherwise call F
23:34:32 <ehird`> but you know that now :)
23:35:24 <ehird`> look how about i just put the impl online :)
23:35:28 <ehird`> it's ruby though and very ugly
23:35:49 <ehird`> and plenty of the examples i wrote when tired and are hopelessly wrong or just speculation like writing a daemon in it
23:36:11 <oklopol> <ehird`> => = dup dup > == or ;; i mean this one
23:36:14 <oklopol> *meant
23:36:17 <ehird`> right, what about it
23:36:26 <oklopol> is that true?
23:36:34 <ehird`> it's a definition
23:36:37 <ehird`> FUNC = CODE ;;
23:36:39 <ehird`> that defines =>
23:37:14 <ehird`> ah i think it should be
23:37:15 <ehird`> => = dup dup > swap swap == or ;;
23:37:21 <oklopol> a b dup dup > == or ;; ===> a b b > == or ;; ===> a 0 == or ;;
23:37:26 <oklopol> as i said earlier
23:37:31 <ehird`> 1 1 -> 1 1 1 1 -> 1 1 false -> 1 false 1 -> false 1 1 -> false true -> true
23:37:43 <oklopol> swap swap == nop
23:37:59 <ehird`> oops.
23:38:04 <oklopol> and
23:38:12 <ehird`> i'm trying to get a b c d -> a b d c -> a d b c :)
23:38:14 <oklopol> still, a a > equals false
23:38:26 <ehird`> oklopol: which is why i do ==, then or
23:38:36 <ehird`> so if == is true and > is false, true is returned
23:38:47 <oklopol> dup > equals false
23:38:50 <oklopol> i think always
23:39:05 <ehird`> hmm that dup is wrong yes
23:39:11 <ehird`> i'm meaning 1 2 -> 1 2 1 2
23:39:13 <ehird`> not 1 2 -> 1 2 2
23:39:17 * ehird` fixes
23:39:24 <ehird`> * 1 2 2 2
23:39:41 <oklopol> dup rot dup rot rot
23:39:53 <oklopol> where a b c rot = b c a
23:40:23 <oklopol> a b -> a b b -> b b a -> b b a a -> b a a b -> b a b a
23:40:23 <ehird`> hrm... i don't think a b c rot = b c a is selfhostedable...better ruby it
23:40:26 <oklopol> hmm
23:40:34 <oklopol> swap dup rot dup rot rot
23:40:46 <oklopol> selfhostedable? :)
23:41:53 <ehird`> programmable in the language itself, not its implementation :)
23:42:04 <ehird`> <= = swap dup rot dup rot rot < rot swap == or ;;
23:42:22 -!- calamari has quit ("Leaving").
23:42:39 <ehird`> ugly :)
23:42:44 <oklopol> yeah, i guess you need a way to reach a depth n specified at runtime to make it tc
23:42:46 <oklopol> or not
23:43:00 <ehird`> anyway, what i mean about selfhostedable is - can i define rot using only pop/swap/etc
23:43:05 <ehird`> or is it a "core" thing
23:43:18 <oklopol> never heard, but i got it, yes
23:45:01 <ehird`> == bottles of beer on the wall,
23:45:01 <ehird`> == bottles of beer.
23:45:02 <ehird`> Take one down, pass it around,
23:45:02 <ehird`> ./core.rb:61:in `-': String can't be coerced into Fixnum (TypeError)
23:45:07 <ehird`> i think i need to debug
23:45:54 <oklopol> nah
23:46:02 <oklopol> i think that's a better 99bob
23:46:37 <ehird`> me too actually
23:46:40 <ehird`> it's catchier
23:46:48 <oklopol> yeah :P
23:46:55 <oklopol> the original is so verbose....
23:47:13 <ehird`> "Equals equals bottles of beer on the wall, equals equals bottles of beer. Take one down, pass it around, core dot rb 61 in minus string can't be coerced into fixnum typeerror."
23:48:07 <oklopol> == essentially is equals though
23:48:26 <oklopol> but i guess you can have multiple variants
23:48:34 <ehird`> equals is assign :P
23:48:55 <oklopol> i mean
23:49:13 <oklopol> '==' can be said 'equals' and '=' 'assign'
23:49:33 <oklopol> while you can just as well say '==' is 'equals equals' and '=' 'equals'
23:49:40 <ehird`> meh
23:56:27 <ehird`> stack = ["swap", "dup", "rot", "dup", "rot", "rot", ">", "rot", "swap", "==", "==", "=="]
23:56:27 <ehird`> wtf.
23:56:33 <ehird`> that's all the function calls
23:56:36 <ehird`> why isn't it...blarh
←2007-05-24 2007-05-25 2007-05-26→ ↑2007 ↑all