|
fast fourier something or another
|
# ? Sep 20, 2012 18:04 |
|
|
# ? May 9, 2024 06:42 |
|
what have you done
|
# ? Sep 20, 2012 18:08 |
|
why should i learn how to do any of these algorithms by hand if i can just call some library in tyool 2012 and not worry about it
|
# ? Sep 20, 2012 18:18 |
|
trex eaterofcadrs posted:fast fourier something or another
|
# ? Sep 20, 2012 18:21 |
|
salted hash browns posted:why should i learn how to do any of these algorithms by hand if i can just call some library in tyool 2012 and not worry about it a library of graph algorithms is either really constraining or crazy unwieldy (cf. boost.graph)
|
# ? Sep 20, 2012 18:22 |
|
does anyone here actually enjoy working with libboost for the sake of working with libboost
|
# ? Sep 20, 2012 18:23 |
|
salted hash browns posted:why should i learn how to do any of these algorithms by hand if i can just call some library in tyool 2012 and not worry about it that knowledge means the difference between boiling the oceans trying to find a solution vs realizing you did dumb and choosing a better method
|
# ? Sep 20, 2012 18:31 |
|
Paracetamol Boy posted:does anyone here actually enjoy working with libboost for the sake of working with libboost that turkey story
|
# ? Sep 20, 2012 18:39 |
|
salted hash browns posted:why should i learn how to do any of these algorithms by hand if i can just call some library in tyool 2012 and not worry about it i had to manually implement BFS a while ago at work
|
# ? Sep 20, 2012 18:41 |
|
yaoi prophet posted:i had to manually implement BFS a while ago at work what was it for? (in case you don't lecture algorithms)
|
# ? Sep 20, 2012 18:43 |
|
Police Academy III posted:what's ur fav A* variant mine is jump point search This is really awesome. First the prisoners dilema and now this, I wonder what other solved-ish problems are going to be destroyed soon.
|
# ? Sep 20, 2012 18:50 |
|
had to handwrite bfs
|
# ? Sep 20, 2012 18:51 |
|
drat that's neat, might look into that for ~*my roguelike*~Paracetamol Boy posted:what was it for? can't say
|
# ? Sep 20, 2012 18:54 |
|
Zombywuf posted:prisoners dilema uh are you referring to tit-for-tat ipd because yeah that is really old
|
# ? Sep 20, 2012 18:56 |
|
ZYNGA STOCK CRASHER posted:had to handwrite bfs if i could choose which shortest-path alg to handwrite i'd probably go with bfs
|
# ? Sep 20, 2012 18:57 |
|
graph traversal algorithms are not even a little bit hard to write, please stop complaining that you had to write one
|
# ? Sep 20, 2012 18:58 |
|
Paracetamol Boy posted:uh are you referring to tit-for-tat ipd because yeah that is really old I mean this: http://www.pnas.org/content/early/2012/05/16/1206569109.full.pdf
|
# ? Sep 20, 2012 19:01 |
|
depends which one but the big 3 are write-offs
|
# ? Sep 20, 2012 19:01 |
|
Otto Skorzeny posted:a library of graph algorithms is either really constraining or crazy unwieldy (cf. boost.graph) the one i used in java was ez and worked great.
|
# ? Sep 20, 2012 19:10 |
|
hehe pnas (that is a nice paper, although it just seems like applied ipd strategies)
|
# ? Sep 20, 2012 19:18 |
|
handwritin code just sucks is what im gettin at here
|
# ? Sep 20, 2012 19:22 |
|
oh i thought you were working out the algorithm but code is easy too just a pain in the rear end lovely third-world high school had a power failure during one of the final exams, so we had to code on paper that was kind of sad
|
# ? Sep 20, 2012 19:25 |
|
maybe i'll dig out CLR from my packed pile of books and look up fibonnaci trees again actually no gently caress that
|
# ? Sep 20, 2012 19:29 |
|
algorithms is a programming language
|
# ? Sep 20, 2012 19:31 |
|
Lysidas posted:make a genome read simulator/assembler yeah suffix tries are drat hard. good stuff though. drat hard. if one wants to stop loving around with wankwork js bingo and learn some Hard Comp Sci this is a good problem to tackle
|
# ? Sep 20, 2012 19:35 |
|
programming thread too heady today; have a joke programcode:
|
# ? Sep 20, 2012 19:52 |
|
Jonny 290 posted:programming thread too heady today; have a joke program stopped reading at the bareword filehandle
|
# ? Sep 20, 2012 20:04 |
|
oh god he didnt use strict and warnings!!!!!
|
# ? Sep 20, 2012 20:07 |
|
YOU MONSTER
|
# ? Sep 20, 2012 20:07 |
|
nice grok
|
# ? Sep 20, 2012 20:07 |
|
Jonny 290 posted:oh god he didnt use strict and warnings!!!!! jonny nooooo use strict use warnings every time
|
# ? Sep 20, 2012 20:21 |
|
Jonny 290 posted:programming thread too heady today; have a joke program Line 1: global typeglobs, is he for real? this isn't 1995 Line 3: ok use a slurp lib, File::Slurp or Perl6::Slurp Line 8: there's 2 things wrong with this line. You really want to be splitting on all whitespace, so C<split ' ', $_> is the preferred form. This is a SPECIAL form of split, it splits out multiple whitespace and fucks off the newline at the end rendering the chomp at line 7 superfluous. The form you want though is just plain C<split>, that uses $_ and splits on the special ' ' pattern (perldoc split, read it). Also, why the unnecessary brackets? This isn't lisp, you're kirk coding with all this unnecessarily punctuation (just made that term up) Line 11: Not a good approach, most performant is to useuse substr+index. If you don't want to and prefer to be lazy, you're still critically wrong. If $_ contained special regex patterns (like '(') your program would die. If you really want to do that, use the form C<s/\Q$_\E/Grog/> or more simply C<s/\Q$_/Grog/>. Furthermore you're compiling new regexes with every iteration so if you care about performance (oh wait it's perl no-one cares) one would be using substr with index Line 12: what's with your 8tab whitespace fetish, you could compress that to C<s/\Q$_/Grog/, last if 4 == length;> Line 8-15: This entire block can be replaced with a regex. C<s/ \b \S{4} \b /Grok/x> There's more, the entire file is quite broken. You're programming Perl like it was C. You need to learn more Perl!
|
# ? Sep 20, 2012 20:25 |
|
everyone needs to learn more perl imho
|
# ? Sep 20, 2012 20:29 |
|
works fine on my end bro, that's cool though i know i can golf it down but wanted to make a joke post in a joke forum as fast as i could. oh also its not 1995 its 1998 code:
Jonny 290 fucked around with this message at 20:33 on Sep 20, 2012 |
# ? Sep 20, 2012 20:31 |
|
rotor posted:everyone needs to learn more perl imho this but java or c# and never a p language. not even once
|
# ? Sep 20, 2012 20:33 |
|
Shaggar posted:this but java or c# and never a p language. not even once
|
# ? Sep 20, 2012 20:37 |
|
Jonny 290 posted:i know i can golf it down but wanted to make a joke post in a joke forum as fast as i could. itt i get emotional about perl
|
# ? Sep 20, 2012 20:42 |
|
its called compiling
|
# ? Sep 20, 2012 20:44 |
|
jonny for the simple stuff you're doing with that array, try map.Perl code:
|
# ? Sep 20, 2012 20:48 |
|
|
# ? May 9, 2024 06:42 |
|
ps you can remove modern::perl and use "print "$_\n" but gently caress that noise
|
# ? Sep 20, 2012 20:49 |