00:02:56 <CakeProphet> I think I might need to do a genetic algorithm for this...
00:04:18 <oerjan> well, you need to decide on a metric
00:04:52 <oerjan> (metric=distance function)
00:05:50 <oerjan> is this something like finding a minimal set of changes?
00:08:42 -!- calamari has quit ("Leaving").
00:09:45 <bsmntbombdood> CakeProphet: There is an algorithm for that in the python stdlib
00:13:47 <bsmntbombdood> get_close_matches is a cool function from that module
00:18:02 <bsmntbombdood> gives 2*<sum of maximal lengths of common substrings>/<combined length>
00:18:09 -!- Pikhq has quit (Read error: 110 (Connection timed out)).
00:19:16 -!- CakeProphet has quit (Success).
00:21:03 -!- calamari has joined.
00:25:36 <calamari> well, I think I'm a kde convert
00:29:56 -!- CakeProphet has joined.
00:30:28 -!- sebbu has quit ("@+").
00:44:54 -!- Figs_ has joined.
00:45:24 -!- Figs has quit (Nick collision from services.).
00:45:47 -!- Figs_ has changed nick to Fogs.
00:45:51 -!- Fogs has changed nick to Figs.
00:49:57 -!- dog4_ has quit ("This computer has gone to sleep").
01:14:36 -!- anonfunc has joined.
01:33:51 <Figs> is that like hamming distance? O.o
01:35:11 <oerjan> ratio("abcde", "edcba")
01:36:36 -!- Figs has left (?).
01:36:38 <oerjan> no consideration of swapping
01:38:36 <oerjan> i don't think the python library handles swapping either, if i read the documentation correctly
01:39:31 <bsmntbombdood> difflib.SequenceMatcher("abcde", "edcba").ratio() => 0
01:40:21 <bsmntbombdood> i dunno how to remove the matches from strings after they are counted
01:42:02 <oerjan> an idea might be to sum something like squares of lengths
01:43:37 <oerjan> then a reversed sequence would match completely in pieces, but the sum would not add up to as much as for equal strings
01:46:25 <oerjan> on the other hand, matching "abcdef" with "acdebf" might give an unintuitive result if you simply remove the match and match the remainder
01:46:46 <oerjan> because after removing "cde", the strings become equal
01:48:07 <bsmntbombdood> simply removing the matches gives ratio("abcde", "edcba") => 1.0
01:48:32 <oerjan> because every piece matches somewhere
01:49:02 <CakeProphet> except this one uses a decision tree to find the shorted possible way to do it.
01:49:15 <oerjan> that's what my square suggestion meant to fix
01:51:26 <bsmntbombdood> and just removing common substrings as we find them
01:55:31 <CakeProphet> ...I could actually split off the recursions into threads... if necessary
02:00:01 -!- anonfunc has quit.
02:00:51 <oerjan> you need to find the _longest_ match first
02:00:55 <CakeProphet> modification to hamming distance tend to work nicely.
02:01:30 <oerjan> you seem to be matching single characters
02:03:47 <CakeProphet> hmmm.... mine works really well for what I'm using it for (finding the closest match to a string within a list of strings)
02:45:49 -!- calamari has quit ("Leaving").
02:59:03 <oerjan> a function for black people with braids?
02:59:46 <bsmntbombdood> methinks python ints should have an __iter__ method
03:01:17 <CakeProphet> hmmm.... don't think that would make much sense
03:02:00 <CakeProphet> makes me think of "every possible floating point value of 6"... which would go on forever.
03:09:19 -!- calamari has joined.
03:19:39 -!- Figs has joined.
03:19:48 <Figs> you guys seen this, right?
03:19:50 <Figs> http://www.nata2.info/d/pictures/f/americans.gif
03:23:26 <Figs> http://www.glowfoto.com/viewimage.php?y=2007&m=03&img=30-224100L&t=jpg&rand=2971&srv=img4
03:41:55 <GregorR> I doubt highly that that's real. (The first one)
03:43:35 <oerjan> http://www.snopes.com/military/lighthse.htm
03:46:50 -!- Arrogant has joined.
03:47:08 <lament> is there an esoteric programming group?
03:48:45 -!- Figs_ has joined.
03:49:58 -!- Figs has quit (Nick collision from services.).
03:50:01 -!- Figs_ has changed nick to Figs.
03:58:10 <lament> there isn't even a brainfuck group :(
04:02:08 -!- jix has quit ("This computer has gone to sleep").
04:02:46 <GregorR> So, I'm thinking of allowing function overloading by allowing calls to arrays of functions.
04:04:51 -!- Pikhq has joined.
04:08:21 -!- Arrogant has quit ("Leaving").
04:14:24 <GregorR> ... you know, multiple functions with the same names, differentiated by their signature...
04:16:00 <GregorR> ... what was that no to? :-P
04:16:29 <bsmntbombdood> <GregorR> ... you know, multiple functions with the same names, differentiated by their signature...
04:16:49 <oerjan> i understand plof is dynamically typed, so the functions would have to check argument types and backtrack to the next function on failure.
04:17:34 <GregorR> oerjan: Plof is dynamically typed with some static typing operators. There is such an operator in function signatures, which enforces that the function is called with the proper arguments.
04:18:16 <GregorR> e.g.: var println = (x as string){...}
04:18:16 <oerjan> ic, so you can declare signatures.
04:19:04 <oerjan> if you wanted you could probably extend that to pattern matching
04:19:15 -!- Figs has left (?).
04:21:46 <GregorR> Um, would pattern matching in that scenario not be a guard by definition?
04:22:57 <oerjan> except a pattern could also deconstruct arguments into variables, and a guard could be a general boolean expression
04:23:27 <GregorR> I think that's getting a bit more complicated than is actually valuable :)
04:24:16 <oerjan> just guards then, perhaps.
04:26:39 <oerjan> say, (x as inrange(1,10))
04:27:23 <oerjan> actually it would be a function to boolean
04:27:27 -!- Pikhq has quit (Read error: 110 (Connection timed out)).
04:27:30 <GregorR> Especially if I implement function overloading as above.
04:28:44 <oerjan> could even have an alternative syntax: (x where x >= 1 and x <= 10)
04:35:01 -!- calamari has quit ("Leaving").
04:49:23 -!- CakeProphet_ has joined.
05:04:14 -!- CakeProphet has quit (Connection timed out).
07:02:02 -!- oerjan has quit ("leaving").
07:02:11 -!- Sgeo has quit ("Ex-Chat").
07:02:31 -!- helios24_ has changed nick to helios24.
07:16:59 -!- GreaseMonkey has joined.
07:59:59 -!- clog has quit (ended).
08:00:00 -!- clog has joined.
08:12:56 <Sukoshi> ObjC is nothing to :3 about.
08:13:23 <Sukoshi> It's like someone grafted on two dissimilar things together into one weird ununiform conglomerate.
08:13:32 <Sukoshi> Of course, it's a lot better than C++, so there you go.
08:14:12 <Sukoshi> My theory about Java is that a long time ago, Java programmers didn't suck and Java ran reliably. I coded a whole bunch of signal processing and NN tools for it, and it was really fast/light.
08:14:53 <Sukoshi> It worked with 64-bit precision numbers the whole time too, and processed about 6 MB of data per-pass, averaging somewhere in the millions for number of passes.
08:16:17 <Sukoshi> My conclusion was that, because Java is the New Thing (TM), every bum coder and his mentally addled half-cousin he slept with ends up using Java and turning codebase into poop. That and I don't like Java's emphasis on New Technologies and the annoying abbreviation technologies.
08:17:44 <Sukoshi> CL would probably be like that too if it had caught on.
08:29:52 -!- ShadowHntr has joined.
08:30:10 -!- Sukoshi has quit ("愛してた。アンタの高い姿を見たことの最初から、見とれた。アンタの真っ黒髪が風の勝手).
09:01:36 -!- ShadowHntr has quit ("End of line.").
09:08:35 -!- dog4 has joined.
09:08:44 -!- dog4 has quit (Remote closed the connection).
09:27:46 -!- Sukoshi has joined.
09:46:14 -!- calamari has joined.
09:59:38 -!- sebbu has joined.
10:24:42 -!- nooga has joined.
10:26:24 <nooga> what happened with that c2bf compiler?
10:45:33 -!- GreaseMonkey has quit ("yays for stack-based thingies!").
10:47:51 -!- calamari has quit (Remote closed the connection).
10:51:21 -!- evilC has joined.
10:51:55 -!- evilC has left (?).
12:00:21 -!- jix has joined.
12:35:58 -!- dog4 has joined.
13:19:04 -!- nazgjunk has joined.
13:22:52 -!- RodgerTheGreat has joined.
13:32:49 -!- jix has quit (Read error: 104 (Connection reset by peer)).
13:33:53 -!- jix has joined.
15:32:45 -!- _filippo_ has joined.
15:32:47 <nooga> i've got my raytracer in sadol working
15:37:07 <nooga> http://pastebin.ca/419385 :D
15:37:34 -!- dog4 has quit ("This computer has gone to sleep").
15:40:14 -!- _filippo_ has left (?).
15:42:06 <nooga> oklopol: echo "2" | BDSM2 raytracer.sad > output.ppm
15:42:24 <nooga> and then open the pm file with some graphic viewer
15:42:45 <oklopol> i had an exam today, but i slept over it
15:43:01 <oklopol> i have one tomorrow as well, hope i have better luck with the alarm
15:43:40 -!- crathman has joined.
15:43:45 -!- crathman has quit (Client Quit).
16:14:54 -!- crathman has joined.
19:10:06 -!- calamari has joined.
19:58:17 <GregorR> Changes for Plof2: 1) Ability to call arrays of functions for overloading, 2) null operator for object combination, 3) Remove ternary comparison and re-add builtin if et cetera, 4) Change return rules: If a value returned from a thin function is actually used (e.g. on the right side of an assignment), it does not continue to fall through. This will allow if() and pals to be used in both the imperative sense and the functional sense.
20:08:12 <GregorR> I see that you're all endlessly fascinated :-P
20:14:46 <oklopol> i think the return thing works but STILL i don't like it
20:15:27 <oklopol> i find it quite unintuitive it checks whether it's used for something
20:16:48 <oklopol> still can't find any problem with it
20:16:56 <GregorR> I'm trying to find a nice middle ground, but can't *sigh*
20:17:05 <GregorR> So I'm going for a good-enough middle ground ;)
20:17:28 <oklopol> i'm pretty sure some kind of quoting might help, but i'm having a hard time grasping the concept fully even
20:17:40 <oklopol> since that's rarely an issue with languages :)
20:18:20 <GregorR> Basically, here's what it would mean:
20:18:50 <GregorR> var foo = :{ if(:{1 == 1}, {return(3);}, else, {return(4);}); }; // returns 3
20:19:01 <GregorR> var foo = :{ var a = if(:{1 == 1}, {return(3);}, else, {return(4);}); }; // sets a to 3
20:20:58 <oklopol> var foo's level's a of foo's a?
20:21:34 <oklopol> will foo become something like struct{int a(==3);}
20:23:50 <oklopol> the "else" thing is quite confusing imo :)
20:24:56 <oklopol> but so... hmm, why does the second one have :{ in the beginning?
20:26:03 <oklopol> ":{" means ":{expression without ; and implicit return }" and "{" means "{ expression; expression; etc.; insert return issue here; }" ?
20:26:59 <GregorR> :{ is a thick function, a function that the return will conclude at. A { is a thin function. I may be able to remove this distinction with my latest change, or not :)
20:27:20 <GregorR> And because I said "var a", I was declaring an a at that scope, so it sets that a. Not very useful :)
20:27:56 <oklopol> ah, so foo will become nothing in the latter?
20:28:03 <oklopol> because you don't return anything
20:28:11 <GregorR> It's a contrived example :P
20:30:24 <GregorR> The thin/thick functions is a concept which helped make returning less ridiculous, but didn't necessarily make it less confusing >_>
20:30:27 <GregorR> I'm still working on it :P
20:30:44 <oklopol> var foo = if(:{1==1}, :{return "1 equals 1!";}, {return "the whole function failed"});
20:30:55 <oklopol> couldn't thick/thin fix the if problem
20:31:01 <oklopol> like that i mean ^^^^^^^^^^^^
20:31:15 <GregorR> The problem is, if is going to be calling those functions.
20:31:30 <GregorR> So the return value will go to 'if'.
20:31:31 -!- helios24_ has joined.
20:31:49 <GregorR> Not (in your example) to foo.
20:32:12 <GregorR> That's what the whole problem with returns was :)
20:32:57 -!- helios24 has quit (Read error: 104 (Connection reset by peer)).
20:33:04 <oklopol> well, obviously... this is too hard for me, i should think about this quite a lot to even be of help at brainstorming :)
20:33:29 <GregorR> I hate how, no matter what concept of programming you follow, there's always a nasty corner :P
20:35:24 <oklopol> : == evaluate at upper level -> :{ would be a normal return given to an "if"... since it would do an expression level return, while a ::{ function would evaluate at the function's level the if is claled at
20:35:38 -!- helios24_ has changed nick to helios24.
20:35:51 <GregorR> It's totally legitimate to pass in functions that you didn't write in right there.
20:35:59 <GregorR> So where the bork would they return to :)
20:36:32 <oklopol> well, they obviously wouldn't be upperlevelized with :
20:49:38 <CakeProphet_> hmmm... you could like... use a bunch of different concepts... perhaps thwarting nasty corners where they breed.
20:50:55 <GregorR> The nasty corner comes from the merging of two concepts :-P
20:51:00 <GregorR> Namely functional and imperative.
20:51:31 <GregorR> Or rather, "every-block-is-a-function" and imperative programming.
21:02:10 <oklopol> i do quite the same thing with oklotalk actually, but i do everything functionally, just let functions modify upper level variables
21:03:06 <oklopol> i'm not sure what i do differently, but there are no problems.... might just be the fact i've not thought that much about that side of the language :P
21:03:23 -!- Sgeo has joined.
21:13:33 -!- ShadowHntr has joined.
21:18:04 <nooga> oklopol: how's your learning?
21:18:37 <oklopol> oh the studying... i browsed through the first 50 pages or so :D
21:20:03 <nooga> echo "10" | BDSM2 raytracer.sad > test.ppm
21:20:14 <nooga> it will output 1200x900 image
21:20:58 <GregorR> That interpreter name makes my brain bleed.
21:21:08 <oklopol> 1. relink it, i've lost the page, 2. i assume i write that on this channel, specify where otherwise :)
21:21:31 <nooga> i'm porting it to SymbianOS 9
21:21:45 <nooga> oklopol: you run it in bash
21:26:04 -!- jix__ has joined.
21:26:56 <nooga> GregorR: i could name the interpreter "CSI - Cool Sadol Interpreter" but it wouldn't be such funny
21:27:25 <oklopol> nooga no windows way to do it? :P
21:28:02 <nooga> BDSM2 ray.sad > test.ppm
21:28:16 <nooga> and then input some number from 1 to 10
21:28:27 -!- crathman has quit ("Chatzilla 0.9.77 [Firefox 2.0.0.3/2007030919]").
21:28:42 <nooga> and open test.ppm in irfanview or such thingy
21:30:32 <nooga> http://pastebin.ca/419385
21:32:33 <oklopol> hmm so... bdsm2.exe takes for 1. argument the source and for second argument the arguments for the sadol program?
21:34:36 -!- jix has quit (Read error: 110 (Connection timed out)).
22:19:00 <SimonRC> call them "function" and "block"?
22:34:30 <CakeProphet_> you would use blocks as loops and conditions and all that jazz... and functions would be your... well... functions.
22:35:20 <SimonRC> maybe you could make functions into thin sugar around blocks
22:36:11 <SimonRC> blocks would need a stack anyway, I suspect, so you could just say that a function is a variable containing a block with a little invisible code in it or something.
22:36:33 <SimonRC> in haskell, a function is just an expression with arguments, after all...
22:36:35 <CakeProphet_> they could always just be... separate entities entirely... :) :) :)
22:37:42 <CakeProphet_> I always find things work strangely when you attempt to de-primitify your primitives.
22:38:44 <CakeProphet_> Alright... so an integer is an object... so what part of the object gives it its value? What gives a string object its value? ...no one seems to know. :P
22:39:42 <lament> what do you mean 'what part'?
22:40:11 <lament> integers are objects, clearly
22:40:18 <CakeProphet_> ...just... a part... with all the vagueness entailed.
22:40:29 <oklopol> well, you have special egofield for that, <object>.__value__=<object>
22:40:30 <lament> i'm not sure if integers have any 'parts' to speak of
22:41:28 <CakeProphet_> hmmm... so would the __value__ of 5 be? 5? hehe... makes sense in a strange way.
22:41:40 <oklopol> but, CakeProphet_, i don't see why you'd have to know the field, an object hides it's value, integer hiding it's value is essentially that value
22:42:00 <bsmntbombdood> INCREMENT CakeProphet_ BY CakeProphet_ GIVING TOQO
22:42:44 <CakeProphet_> mostly that question arises when I subclass an integer... when your working in the integers enternals there's nothing directly accessible that gives 5 its 5ness.
22:43:35 <lament> that's just a matter of representing your integers nicely.
22:43:50 <CakeProphet_> the whole "everything is an object" notion is infinitely recursive... you have objects consisting of objects.... the tree needs leaves at some point.
22:44:01 <lament> the problem is that preferred representations in math care about operations more than about objects themselves
22:44:24 <lament> "Integers are a set (of featureless objects, that is) that behaves in a certain way under certain operations)"
22:44:37 <lament> however, you can define them in different ways, for example peano arithmetic
22:44:55 <lament> you have a magical singleton object zero
22:44:58 <oklopol> CakeProphet_ what's wrong with infinite recursions?
22:45:05 <lament> and then you have objects with field 'pred'
22:45:13 <CakeProphet_> ...it would make more sense to me to simply have an unexplained axiom... the integer... the string... there's nothing more under the hood to know.
22:45:17 <oklopol> it's just a conceptual recursion and does not do any harm
22:45:18 <lament> and if your objects pred is zero, then you know the object is one
22:46:21 <lament> but in most cases, math treats integers as labeled "points" with no content
22:47:29 <lament> two integers are distinguishable if their labels are different
22:47:43 <lament> you can't say anything more than that unless you define operations on the integers
22:47:58 <CakeProphet_> there's nothing wrong with a conceptual recursion... in msot cases. It really doesn't harm anything... it just seems silly to confuse everything with the notion that everything needs an underlying explaination.
22:48:41 <lament> CakeProphet_: "needs an underlying explanation" is different from "consists of parts"
22:49:46 <lament> i think it's pretty silly for integers to have "properties", certainly
22:51:56 <CakeProphet_> consisting of parts amounts to an explaination... What's a bench? Wood and metal.. What's wood? Cellulose. What's Cellulose? (C6H10O5)n. What's Carbon? 6 electrons. What's an electron? <insert crazy quantum physics shit>
22:52:21 <lament> electrons, however, don't consist of parts
22:52:33 <lament> we can still "explain" them by detailing their behavior
22:53:37 <CakeProphet_> derailing from computer science... this would get into notions of identity, THE LEAVES OF THE REALITY GRAPH, and human cognition. -wiggles his philosophers hat pre-emptively-
22:56:09 <lament> fortunately integers are not 'real' in any way :)
22:56:24 <lament> PUN NOT INTENDED AND I SHALL SMITE YOU IF YOU MAKE IT
22:58:40 <oklopol> lament: ACTUALLY INTEGERS ARE REALS, THEY'RE A SUBSET OF REALS
23:01:33 -!- ChanServ has set channel mode: +o lament.
23:01:37 -!- oklopol has joined.
23:01:43 -!- lament has set channel mode: -o lament.
23:02:58 <CakeProphet_> and now stuff is defined by what its a part of.
23:02:58 <oklopol> can't we do that tomorrow? :|
23:03:14 <lament> CakeProphet_: that's Prolog i think
23:03:22 <lament> CakeProphet_: the "is a" relationship :)
23:03:29 <lament> oh, i guess that's different
23:03:37 <CakeProphet_> well.... is a is something like... a type check
23:03:57 * CakeProphet_ is just having a little thought experiment here.
23:03:59 <lament> object a contains fields foo and bar
23:04:06 <lament> fields foo and bar are contained in object a
23:04:09 <lament> it's the same thing...
23:05:45 <lament> a is a part of the universe.
23:06:27 <CakeProphet_> hmmm... same thing essentially... just... backwards. HMMMM HOW SURPISING
23:06:33 <CakeProphet_> THAT SOMETHING REVERSED IS THE SAME THING REVERSED.
23:07:44 <lament> let's close the loop while we're at it.
23:07:55 <lament> The universe is a part of an integer :)
23:08:46 -!- helios24 has quit (zelazny.freenode.net irc.freenode.net).
23:08:46 -!- calamari has quit (zelazny.freenode.net irc.freenode.net).
23:08:46 -!- Sukoshi has quit (zelazny.freenode.net irc.freenode.net).
23:08:46 -!- GregorR has quit (zelazny.freenode.net irc.freenode.net).
23:08:47 -!- sekhmet has quit (zelazny.freenode.net irc.freenode.net).
23:08:47 -!- SimonRC has quit (zelazny.freenode.net irc.freenode.net).
23:08:47 -!- ShadowHntr has quit (zelazny.freenode.net irc.freenode.net).
23:08:48 -!- bsmnt_bot has quit (zelazny.freenode.net irc.freenode.net).
23:08:48 -!- tokigun has quit (zelazny.freenode.net irc.freenode.net).
23:08:48 -!- RodgerTheGreat has quit (zelazny.freenode.net irc.freenode.net).
23:08:48 -!- nazgjunk has quit (zelazny.freenode.net irc.freenode.net).
23:08:48 -!- CakeProphet_ has quit (zelazny.freenode.net irc.freenode.net).
23:08:48 -!- gg_ has quit (zelazny.freenode.net irc.freenode.net).
23:08:50 -!- Sgeo has quit (zelazny.freenode.net irc.freenode.net).
23:08:50 -!- lament has quit (zelazny.freenode.net irc.freenode.net).
23:08:51 -!- puzzlet has quit (zelazny.freenode.net irc.freenode.net).
23:08:51 -!- sp3tt has quit (zelazny.freenode.net irc.freenode.net).
23:08:51 -!- wooby has quit (zelazny.freenode.net irc.freenode.net).
23:08:51 -!- Izzy7 has quit (zelazny.freenode.net irc.freenode.net).
23:08:52 -!- cmeme has quit (zelazny.freenode.net irc.freenode.net).
23:08:52 -!- meatmanek has quit (zelazny.freenode.net irc.freenode.net).
23:09:10 -!- Sgeo has joined.
23:09:10 -!- lament has joined.
23:09:10 -!- puzzlet has joined.
23:09:10 -!- sp3tt has joined.
23:09:16 -!- calamari has joined.
23:09:16 -!- Sukoshi has joined.
23:09:16 -!- GregorR has joined.
23:09:16 -!- sekhmet has joined.
23:09:16 -!- SimonRC has joined.
23:09:23 -!- helios24 has joined.
23:09:26 -!- wooby has joined.
23:09:26 -!- Izzy7 has joined.
23:09:26 -!- cmeme has joined.
23:09:26 -!- meatmanek has joined.
23:09:29 -!- dog4 has joined.
23:09:29 -!- ShadowHntr has joined.
23:09:29 -!- bsmnt_bot has joined.
23:09:29 -!- tokigun has joined.
23:10:02 -!- RodgerTheGreat has joined.
23:10:02 -!- nazgjunk has joined.
23:10:02 -!- CakeProphet_ has joined.
23:10:02 -!- gg_ has joined.
23:10:24 -!- dog4 has left (?).
23:11:27 -!- wooby has quit.
23:17:06 <lament> to see the world in a grain of sand
23:17:10 <lament> and heaven in a wild flower
23:17:17 <lament> hold infinity in the palm of your hand
23:17:22 <lament> and eternity in an hour
23:17:37 <lament> i never realized that poem was about OOP.
23:21:14 <oklopol> oh i do, now that i think about it
23:23:13 <CakeProphet_> .....I just think this is incredible. http://en.wikipedia.org/wiki/Attosecond
23:28:20 * oklopol has a hard time keeping up with all this intellectualism
23:28:40 <lament> CakeProphet_: what's incredible?
23:47:54 <bsmntbombdood> 1 attosecond is the amount of time it takes for light to travel the length of three hydrogen atoms