adrien changed the topic of #ocaml to: Discussions about the OCaml programming language | http://caml.inria.fr/ | OCaml 4.00.1 http://bit.ly/UHeZyT | http://www.ocaml-lang.org | Public logs at http://tunes.org/~nef/logs/ocaml/
lolcathost has quit [Ping timeout: 248 seconds]
lolcathost has joined #ocaml
Progster has joined #ocaml
travisbrady has joined #ocaml
emmanuelux has quit [Remote host closed the connection]
netrino has left #ocaml []
thomasga1 has quit [Quit: Leaving.]
fraggle_ has quit [Read error: Connection reset by peer]
cdidd has quit [Remote host closed the connection]
Yoric has joined #ocaml
madroach has quit [Ping timeout: 244 seconds]
fraggle_ has joined #ocaml
madroach has joined #ocaml
turingtest has quit [Quit: turingtest]
sepp2k1 has quit [Remote host closed the connection]
Progster has quit [Ping timeout: 276 seconds]
travisbrady has quit [Quit: travisbrady]
Yoric has quit [Ping timeout: 252 seconds]
travisbrady has joined #ocaml
gnuvince has joined #ocaml
astertronistic has joined #ocaml
Progster has joined #ocaml
lolcathost has quit [Quit: brb]
lolcathost has joined #ocaml
Progster has quit [Ping timeout: 264 seconds]
lolcathost has quit [Ping timeout: 276 seconds]
lolcathost has joined #ocaml
astertronistic has quit [Ping timeout: 264 seconds]
travisbrady has quit [Quit: travisbrady]
astertronistic has joined #ocaml
jamii has quit [Ping timeout: 246 seconds]
mjonsson has quit [Ping timeout: 246 seconds]
Yoric has joined #ocaml
andreypopp has joined #ocaml
larhat has quit [Quit: Leaving.]
testcocoon has quit [Read error: Operation timed out]
testcocoon has joined #ocaml
Yoric1 has joined #ocaml
Yoric has quit [Ping timeout: 252 seconds]
Yoric1 has quit [Ping timeout: 246 seconds]
andreypopp has quit [Quit: sleep]
Kakadu has joined #ocaml
larhat has joined #ocaml
lolcathost has quit [Quit: test]
answer_42 has joined #ocaml
ankit9 has joined #ocaml
pango is now known as pangoafk
lolcathost has joined #ocaml
ankit9 has quit [Ping timeout: 246 seconds]
Yoric has joined #ocaml
hkBst has joined #ocaml
ankit9 has joined #ocaml
ankit9 has quit [Remote host closed the connection]
fusillia has joined #ocaml
Cyanure has joined #ocaml
ontologiae has joined #ocaml
lolcathost has quit [Ping timeout: 260 seconds]
orbitz has quit [Quit: leaving]
orbitz has joined #ocaml
ontologiae has quit [Ping timeout: 248 seconds]
ivan\ has quit [Ping timeout: 246 seconds]
wagle_ has joined #ocaml
wagle has quit [Ping timeout: 246 seconds]
ivan\ has joined #ocaml
andreypopp has joined #ocaml
ftrvxmtrx has quit [Quit: Leaving]
answer_42 has quit [Ping timeout: 276 seconds]
ontologiae has joined #ocaml
djcoin has joined #ocaml
thomasga has joined #ocaml
f[x] has joined #ocaml
beckerb has joined #ocaml
Neros has quit [Read error: Operation timed out]
Neros has joined #ocaml
cago has joined #ocaml
Kakadu has quit [Quit: Konversation terminated!]
_andre has joined #ocaml
Neros has quit [Ping timeout: 245 seconds]
Neros has joined #ocaml
ftrvxmtrx has joined #ocaml
f[x] has quit [Quit: Leaving]
nicoo has quit [Ping timeout: 246 seconds]
rossberg has quit [Remote host closed the connection]
f[x] has joined #ocaml
avsm has joined #ocaml
avsm1 has joined #ocaml
avsm2 has joined #ocaml
avsm1 has quit [Ping timeout: 268 seconds]
avsm has quit [Ping timeout: 268 seconds]
cdidd has joined #ocaml
mcclurmc is now known as mcclurmc_away
sepp2k has joined #ocaml
ftrvxmtrx has quit [Quit: Leaving]
ftrvxmtrx has joined #ocaml
thomasga1 has joined #ocaml
thomasga has quit [Read error: Connection reset by peer]
Progster has joined #ocaml
avsm2 has quit [Quit: Leaving.]
Progster has quit [Ping timeout: 252 seconds]
<rixed> batteries: make doc is broken for me on batteries master, because of commit 6cf384efa which adds a BatStats that can't be found :-/
avsm has joined #ocaml
<pippijn> wow, 57% of the time is spent on string_of_int
Neros has quit [Read error: Operation timed out]
<pippijn> now it's gone
<pippijn> 40% is now Buffer.add_string
<pippijn> I probably can't do much about that
<rixed> pippijn: start with bigger buffers maybe?
<pippijn> rixed: it never grows
<rixed> pippijn: then use a string to begin with :p
<pippijn> right
<pippijn> :)
<pippijn> actually it *can* grow
<pippijn> it just doesn't, because I already have a big enough buffer
<pippijn> now it's 11%
xavierm02 has joined #ocaml
<yezariaely> There are three implementations of the very same function: http://pastebin.com/vq5nuxf0 Any hints which I should use, and why? I can't really decide...
<yezariaely> And I like my code to be readable...
<thizanne> http://paste.awesom.eu/M3G i would probably write this yezariaely
<thizanne> http://paste.awesom.eu/Xa2 or this
<thizanne> but this is nto strictly equivalent
<yezariaely> no, it has a different type :) but very interessting
<thizanne> in fact it ill not do the same thing if you call it with unknown polymorphic variants
Yoric has quit [Ping timeout: 240 seconds]
mcclurmc_away is now known as mcclurmc
<yezariaely> thizanne, the last version I like the most. Thank you very much!
answer_42 has joined #ocaml
mjonsson has joined #ocaml
mehdid has quit [Ping timeout: 240 seconds]
avsm has quit [Quit: Leaving.]
mehdid has joined #ocaml
avsm has joined #ocaml
gnuvince has quit [Ping timeout: 252 seconds]
astertronistic has quit [Ping timeout: 260 seconds]
avsm has quit [Quit: Leaving.]
jamii has joined #ocaml
BiDOrD_ has joined #ocaml
BiDOrD has quit [Ping timeout: 260 seconds]
mjonsson has quit [Ping timeout: 255 seconds]
Submarine has joined #ocaml
<xavierm02> should I keep the list of prime numbers in increasing order so that I can say "this new number isn't a prime" faster
<xavierm02> or should I reverse it so that prepending new numbers is faster
<xavierm02> ?
sivoais has quit [Ping timeout: 260 seconds]
sivoais has joined #ocaml
<flux> you could use a set of integets, where appending is relatively fast and iterating from the beginning is fast as well. sadly the searching phase would need to use exceptions.
<flux> actually no, you could use Set.S.exists
<xavierm02> ok ty :)
Yoric has joined #ocaml
tizoc has quit [Remote host closed the connection]
tizoc has joined #ocaml
avsm has joined #ocaml
avsm has quit [Client Quit]
Neros has joined #ocaml
smondet has joined #ocaml
<xavierm02> I just tried to implement quicksort on lists http://pastebin.com/Xkfya4K9 and I'd really appreciate if someone could check if I've done something stupid
<xavierm02> Also, how could I check it's actually O(n log n )?
<flux> I think you might find mergesort more suitable for functional languaegs
<flux> quicksort isn't guaranteed to be O(n log n), btw
<xavierm02> well I need to see those things at least once
<xavierm02> yeah but in the average case it is
<flux> just create random lists of length 2^n and see how long it takes
<flux> then plot a chart :)
<xavierm02> for "how long it takes", I should use Sys.time?
<xavierm02> at the beginning and at the end?
<|jbrown|> @ is O(n), which might ruin your overall complexity
<|jbrown|> O(n) in the length of one of the arguments, that is. Not sure which, offhand :-).
Neros has quit [Ping timeout: 260 seconds]
travisbrady has joined #ocaml
Neros has joined #ocaml
Neros has quit [Ping timeout: 246 seconds]
Neros has joined #ocaml
fusillia has quit [Ping timeout: 246 seconds]
<thelema> |jbrown|: the first argument
ontologi1e has joined #ocaml
<|jbrown|> figures.
ontologiae has quit [Ping timeout: 255 seconds]
<flux> xavierm02, yes
<flux> xavierm02, with enough data to make the time significant
ftrvxmtrx has quit [Quit: Leaving]
<thelema> or use the bench library (https://github.com/thelema/bench) or ocaml-benchmark (http://ocaml-benchmark.sourceforge.net/)
<thelema> err, old link...
<flux> is there something with built-in charting features?-)
<thelema> flux: bench has benchplot to make plots
<flux> nice, thought it didn't from the lack of file names describing such functionality
<thelema> benchplot is a bit of a red-headed stepchild, because of its dependency on Archimedes
<thelema> Bench definitely deserves better "howto"
<thelema> but there's plans to integrate it into ocaml-benchmark
<thelema> if only I had time
hongboz has joined #ocaml
Neros has quit [Read error: Connection reset by peer]
hkBst has quit [Quit: Konversation terminated!]
Neros has joined #ocaml
chambart has joined #ocaml
cago has left #ocaml []
<xavierm02> on the page
<xavierm02> the 2^{30}
<xavierm02> is really small
<xavierm02> at least the 30 is
<orbitz> xavierm02: does it matter?
Neros has quit [Ping timeout: 260 seconds]
<xavierm02> not really
<xavierm02> but you could at a span with a font-size
<xavierm02> to make it readable
<orbitz> Me? I'm not in control of ocamldoc
<xavierm02> well
<xavierm02> the people in control of it
<xavierm02> i guess they must be in this chan
<orbitz> I doubt it
<Qrntz> unlikely
avsm has joined #ocaml
<xavierm02> with what should i seed the random function?
<xavierm02> the system time?
<Qrntz> you can just call «Random.self_init ()»
<xavierm02> it's just to check if I have O( n log n)
<xavierm02> right
<xavierm02> ty i missed that one :o
<orbitz> what is to check ifyou have O(n log n)?
<xavierm02> i generate random lists to check is my quicksort behave correctly
<xavierm02> behaves
<xavierm02> --------
<xavierm02> I gives me a warning that the expression should be of type unit
<xavierm02> for i = 1 to 1000 do
<orbitz> so you're going to tiem it a bunch of times and fit it to a curve?
<xavierm02> quicksort ( random_list 10000 1000 );
<xavierm02> done
<xavierm02> well
<orbitz> ignore (quicksort (random_list...));
<xavierm02> i just check 2 different length
<orbitz> you might want to learn how to derive time complexity in a more rigurou way
<xavierm02> ty :)
<xavierm02> i know that for iterative things
<xavierm02> but when I do recursive ones
<xavierm02> i kinda get lost
<xavierm02> but it's the next chapter in my book ^.^
tac has joined #ocaml
andreypopp has quit [Quit: sleep]
Neros has joined #ocaml
ontologi1e has quit [Ping timeout: 245 seconds]
avsm has quit [Quit: Leaving.]
ontologiae has joined #ocaml
avsm has joined #ocaml
cdidd has quit [Ping timeout: 260 seconds]
gnuvince has joined #ocaml
avsm has quit [Client Quit]
trotro has joined #ocaml
trotro has quit [Read error: Connection reset by peer]
notk0 has joined #ocaml
<notk0> is it true that ocaml is a bad language ?
sepp2k1 has joined #ocaml
sepp2k has quit [Ping timeout: 246 seconds]
<thelema> notk0: of course it is true.
<notk0> thelema: what can I do as a user?
<thelema> use the best language you know for your task.
<notk0> the best language I know is visual basic but it;s not supported on windows 8 unfortunately
<notk0> I was told to migrate to Ocaml
<thelema> notk0: if your target is windows 8, use F#
<notk0> I don't want to use .NET
<notk0> no F#
mcclurmc is now known as mcclurmc_away
<notk0> thelema: is there a way to make ocaml import visual basic dlls ?
chambart has quit [Read error: Operation timed out]
<notk0> ocaml itself is written in visual basic right?
<thelema> probably not easily.
<_habnabit> is there an ocaml FFI even?
<notk0> what is FFI?
* thelema is treating notk as a troll
<_habnabit> well, yes
<_habnabit> you don't have him on ignore?
<thelema> I do now. I should have when he first came in.
<notk0> why would anyone ignore me
<notk0> you guys suck, ignoring people with obvious need of help
<enkomax> <notk0> ocaml itself is written in visual basic right? <--- for this alone
<notk0> that's what I read
<_habnabit> http://ocamlffi.sourceforge.net/ well i guess that's one way to do an FFI
<enkomax> where
<thelema> enkomax: that was when I was sure.
<enkomax> trolling is so last year...
<notk0> there is also swig to interface Ocaml with C and other languages as well I think
<enkomax> where did u read vb part?
<Qrntz> don't feed the trolls
<notk0> enkomax: well since Ocaml doesn't keep up with modern languages you can expect trolls to not keep up either, 1 year lag
<Qrntz> especially bad ones
<notk0> enkomax: vb is written in C right? I assume
<notk0> oh common guys
<notk0> thats why nobody uses Ocaml because you are not as cool as people from other channels
notk0 has left #ocaml []
<Qrntz> good riddance
larhat has quit [Quit: Leaving.]
travisbrady has quit [Quit: travisbrady]
larhat has joined #ocaml
<wieczyk> Where is wmeyer?
lolcathost has joined #ocaml
ontologiae has quit [Ping timeout: 252 seconds]
ftrvxmtrx has joined #ocaml
<flux> _habnabit, now all I need to look how long ago 'Last modified: Sunday, August 19th. ' is :)
<_habnabit> heh
<_habnabit> $ HEAD -s http://ocamlffi.sourceforge.net/ | grep -i last-modified
<_habnabit> Last-Modified: Sun, 19 Aug 2001 18:18:48 GMT
<flux> but the latest release is from 2009
<flux> surprisingly long time span for a project..
<flux> I think all these automatic c/h->ocaml-converters are bound to fail
<flux> what I would like to see (and I've told this numerous times earlier, but still haven't gotten on it :)) would be a binding generator library
<flux> it would come with a header/c-code/some other parser and a module for generating C code
<flux> and then you would piece these together to create a binding generator for some C library X
larhat has quit [Quit: Leaving.]
larhat has joined #ocaml
mcclurmc_away is now known as mcclurmc
<adrien> hmmm, not the first time notk0 does that; should check the logs when I have time
<Qrntz> adrien, about the third one
larhat has quit [Quit: Leaving.]
larhat has joined #ocaml
tane has joined #ocaml
tac is now known as tac-lunch
Cyanure has quit [Read error: Connection reset by peer]
andreypopp has joined #ocaml
tac-lunch is now known as tac
travisbrady has joined #ocaml
cdidd has joined #ocaml
emmanuelux has joined #ocaml
lolcathost has quit [Quit: lag]
lolcathost has joined #ocaml
Cyanure has joined #ocaml
gnuvince has quit [Ping timeout: 246 seconds]
mcclurmc is now known as mcclurmc_away
smondet has quit [Ping timeout: 240 seconds]
_andre has quit [Quit: leaving]
smondet has joined #ocaml
K_F has joined #ocaml
pangoafk is now known as pango
gnuvince has joined #ocaml
ppseafield has joined #ocaml
gnuvince has quit [Ping timeout: 248 seconds]
dskippy has joined #ocaml
gustav__ has joined #ocaml
dskippy1 has joined #ocaml
emmanuelux has quit [Quit: emmanuelux]
lolcathost has quit [Quit: Restarting...]
rwmjonesKVMForum is now known as rwmjones
dskippy has quit [Ping timeout: 268 seconds]
rwmjones is now known as rwmjonesKVMForum
lolcathost has joined #ocaml
beckerb has quit [Ping timeout: 260 seconds]
Submarine has quit [Quit: Leaving]
tac_ has joined #ocaml
tac has quit [Ping timeout: 245 seconds]
TDJACR has joined #ocaml
tac_ is now known as tac-nap
hongboz has quit [Ping timeout: 252 seconds]
dskippy1 has quit [Quit: Leaving.]
Znudzon has joined #ocaml
Znudzon is now known as deu5
Yoric has quit [Ping timeout: 246 seconds]
TDJACR has quit [Ping timeout: 245 seconds]
answer_42 has quit [Quit: WeeChat 0.3.9]
larhat has quit [Quit: Leaving.]
TDJACR has joined #ocaml
<gustav__> Eureka.
djcoin has quit [Ping timeout: 255 seconds]
Yoric has joined #ocaml
mjonsson has joined #ocaml
TDJACR_ has joined #ocaml
TDJACR has quit [Quit: Reconnecting]
Yoric has quit [Ping timeout: 246 seconds]
TDJACR_ has quit [Ping timeout: 252 seconds]
TDJACR has joined #ocaml
Yoric has joined #ocaml
<pippijn> atdgen generates really ugly code
<pippijn> with Obj.set_field and stuff
gustav__ has quit [Read error: Connection reset by peer]
Yoric has quit [Ping timeout: 252 seconds]
larhat has joined #ocaml
ppseafield has quit [Quit: Leaving.]
chambart has joined #ocaml
mathieui has quit [Ping timeout: 255 seconds]
tane has quit [Quit: Verlassend]
emmanuelux has joined #ocaml
mathieui has joined #ocaml
cdidd has quit [Ping timeout: 265 seconds]
andreypopp has quit [Quit: sleep]
dskippy has joined #ocaml
dskippy has quit [Quit: Leaving.]
cdidd has joined #ocaml
mcclurmc_away is now known as mcclurmc
mcclurmc is now known as mcclurmc_away
cdidd has quit [Ping timeout: 240 seconds]
larhat has quit [Quit: Leaving.]
larhat has joined #ocaml
deu5 has quit [Remote host closed the connection]
smondet has quit [Read error: Operation timed out]
cdidd has joined #ocaml
thomasga1 has quit [Quit: Leaving.]
Cyanure has quit [Remote host closed the connection]
gnuvince has joined #ocaml
travisbrady has quit [Quit: travisbrady]
Yoric has joined #ocaml
lolcathost has quit [Remote host closed the connection]
tac-nap has quit [Ping timeout: 245 seconds]
jamii has quit [Ping timeout: 255 seconds]
Zerker has joined #ocaml
<Zerker> match list with h::h::tl -> "Yay duplicate"
lolcathost has joined #ocaml
<Zerker> doesn't work, do I really need to make an if statement?
<pippijn> Zerker: match list with h1::h2::_ when h1 = h2 -> "yay"
<Zerker> else recur h2::tl?
<Zerker> Okay, that's a "yep I do", thank you.
<pippijn> Zerker: match list with h1::h2::_ when h1 = h2 -> "yay" | _::tl -> recur tl
emmanuelux has quit [Remote host closed the connection]
<Zerker> Oh that's how when works. Yay!
Zerker has quit [Quit: Colloquy for iPad - Timeout (10 minutes)]
|jbrown| has quit [Ping timeout: 252 seconds]
|jbrown| has joined #ocaml
walter has joined #ocaml
Yoric has quit [Ping timeout: 255 seconds]
Yoric has joined #ocaml