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...
<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