Perl 6 - the future is here, just unevenly distributed

IRC log for #rosettacode, 2014-01-04

| Channels | #rosettacode index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
02:45 mikemol|zoe joined #rosettacode
04:18 mikemol|zoe joined #rosettacode
06:09 mwn3d joined #rosettacode
09:29 eMBee joined #rosettacode
09:29 Hypftier joined #rosettacode
09:29 ttmrichter joined #rosettacode
09:29 mwn3d joined #rosettacode
09:29 matti joined #rosettacode
09:29 BenBE joined #rosettacode
09:29 Util joined #rosettacode
09:29 sirdancealo2 joined #rosettacode
09:29 relrod_ joined #rosettacode
09:29 sorear joined #rosettacode
09:29 rublets joined #rosettacode
09:29 ingy joined #rosettacode
09:29 realazthat joined #rosettacode
09:29 xfix joined #rosettacode
09:29 FireFly joined #rosettacode
09:29 camelia joined #rosettacode
09:30 Giomancer joined #rosettacode
09:30 eel22 joined #rosettacode
09:30 Coderjoe joined #rosettacode
09:30 lambdabot joined #rosettacode
09:30 TimToady joined #rosettacode
09:30 ivanshmakov joined #rosettacode
09:30 fedaykin joined #rosettacode
09:31 relrod_ joined #rosettacode
09:35 kpreid joined #rosettacode
09:53 ChanServ joined #rosettacode
09:53 opticron joined #rosettacode
09:54 ChanServ left #rosettacode
11:21 Pixelz` joined #rosettacode
14:21 mwn3d1 joined #rosettacode
14:22 mwndsphonesucks joined #rosettacode
15:18 mwn3d joined #rosettacode
16:50 relrod joined #rosettacode
17:13 mwn3d joined #rosettacode
17:18 NTQ joined #rosettacode
17:18 NTQ Hi
17:18 NTQ How can I sort the languages by the amount of resolved tasks?
17:18 mwn3d1 joined #rosettacode
17:19 NTQ hi mwn3d
17:30 NTQ hi mwn3d1
17:30 mwn3d1 NTQ: hello
17:41 mwn3d joined #rosettacode
17:44 NTQ mwn3d: Can you tell me how to sort the languages by the amount of resolved tasks?
17:46 mwn3d NTQ: the way I usually do it is by looking at http://rosettacode.org/wiki/​Special:MostLinkedCategories. You can see how many members each category has and you just have to recognize language names.
17:48 NTQ Oh, thank you. That is what I am looking for
18:00 TimToady or just look at http://rosettacode.org/wiki/Rosetta​_Code/Rank_languages_by_popularity
18:00 TimToady (arguably misnamed :)
19:47 kpreid joined #rosettacode
19:48 sirdancealo2 git clone https://github.com/acmeism/RosettaCodeData.git ; cd RosettaCodeData/Lang; for i in *; do echo -n $i ""; ls $i | wc -l; done | sort  -k 2 -n -r
19:49 * sirdancealo2 exceeded his daily allowed bash dose by 200% and drops on the floor
20:03 ivanshmakov sirdancealo2: JFTR, the “proper” way to write “the value of var” in POSIX Shell is "$var". On the contrary, $var means “the words that are stored in var”, so var='a b c' ; ls -- $var becomes ls a b c — a call to ls(1) with /three/ arguments.
20:04 * sirdancealo2 twitches
20:04 ivanshmakov Personally, I’d code it as, say: cd RosettaCodeData/Lang && find -mindepth 2 -maxdepth 2 -printf %h\\n | uniq -c | sort -rn.
20:06 ivanshmakov Or, to avoid find(1) (for no reason at all): cd RosettaCodeData/Lang && for d in */ ; do set -- "$d"/* ; echo "$d $#" ; done | sort -k 2 -rn
20:06 FireFly set?
20:06 ivanshmakov $ set -- foo bar baz ; echo "$2 $#" # → bar 3
20:07 ivanshmakov (That is, one can count files in a directory with pure Shell! Hooray!)
20:07 FireFly Oh.
20:08 ivanshmakov s/files/filenames/, as a single file may be referenced by multiple filenames.
20:10 ivanshmakov POSIX requires that the Shell supports a single array (vector): "$@". Bash allows an arbitrary number of arrays, but that’s not necessary for the task at hand.
20:19 FireFly ls | xargs -d'\n' -I{} echo echo -n {} '\ ' \; ls {} \| wc -l | sh
20:19 * FireFly hides
20:24 ivanshmakov … Now that the filenames are expanded by the Shell twice, we’re one step closer to a perfect unpredictable code. (And where’s the sort, BTW?)
20:28 FireFly Oh, I forgot about that part
20:34 ivanshmakov Another idiom I’d often follow when gathering statistics of some kind is that of $ find … | gawk … (or perhaps even $ find … | perl …, although that would imply some access to the files themselves, and not just counting the filenames.)
23:11 mikemol|zoe joined #rosettacode
23:39 mwn3d1 joined #rosettacode

| Channels | #rosettacode index | Today | | Search | Google Search | Plain-Text | summary