This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iomanip> | |
#include <iostream> | |
#include <boost/accumulators/accumulators.hpp> | |
#include <boost/accumulators/statistics/variance.hpp> | |
#include <boost/accumulators/statistics/stats.hpp> | |
namespace bacc = boost::accumulators; | |
static void | |
demo(const double base) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
t\spec\S32-num\power.rakudo.moar .. | |
1..76 | |
ok 1 - 0 ** 0 == 1 | |
ok 2 - 0 ** 1 == 0 | |
ok 3 - 1 ** 2 == 1 | |
ok 4 - 4 ** 0 == 1 | |
ok 5 - 4 ** 1 == 4 | |
ok 6 - 4 ** 2 == 16 | |
ok 7 - 0 ** 4553535345364535345634543534 == 0 | |
ok 8 - 1 ** 4553535345364535345634543534 == 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
t\spec\S32-io\spurt.t .. | |
1..35 | |
ok 1 - spurting Buf ok | |
ok 2 - spurting txt ok | |
ok 3 - spurt with enc | |
ok 4 - spurting Buf with append | |
ok 5 - spurting txt with append | |
not ok 6 - createonly creates file with Buf | |
# Failed test 'createonly creates file with Buf' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
t\spec\S32-io\pipe.t .. | |
1..14 | |
ok 1 - shell/run(:out).out is a Proc | |
ok 2 - shell/run(:out).out is an IO::Pipe | |
ok 3 - shell/run(:out) returns something trueish on success | |
ok 4 - Proc::Status.exitcode is zero for a successful run | |
ok 5 - Proc::Status.status is zero for a successful run | |
ok 6 - got correct output | |
1..6 | |
ok 1 - Child succeeds but does not print anything |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ tar -xvf samtools-0.1.18.tar.bz2 | |
$ cd samtools-0.1.18 | |
$ make CFLAGS=-fPIC | |
Note, there are problems building this with GCC 5.3.0 because of the | |
use of `inline` with functions that are supposed to go in to a library. | |
Once that is fixed, library builds fine. | |
$ export SAMTOOLS=`pwd`; ~/perl/5.22.0/bin/cpanm Bio::DB::Sam | |
--> Working on Bio::DB::Sam |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env perl | |
=for comment | |
Office of the Unites States Trade Representative released the full text of the | |
Trans-Pacific Partnership trade agreement on November 5, 2015. For some reason, | |
it was released in 239 individual PDF documents, instead of a single file. | |
ToC at https://ustr.gov/trade-agreements/free-trade-agreements/trans-pacific-partnership/tpp-full-text |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Uniform random floats: How to generate a double-precision | |
* floating-point number in [0, 1] uniformly at random given a uniform | |
* random source of bits. | |
* | |
* Copyright (c) 2014, Taylor R Campbell | |
* | |
* Verbatim copying and distribution of this entire article are | |
* permitted worldwide, without royalty, in any medium, provided | |
* this notice, and the copyright notice, are preserved. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
http://www.nu42.com/2015/06/quorum-creators-cannot-write-quorum.html | |
Quorum is a programming language created by Stefik et al. In a 2011 paper, the authors infamously proclaimed: | |
Results showed that while Quorum users were afforded significantly | |
greater accuracy compared to those using Perl and Randomo, Perl users | |
were unable to write programs more accurately than those using a | |
language designed by chance. | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env perl | |
use v5.20; | |
=for commentary | |
This is my second entry in brian d foy's "Be Better than Quorum" challenge | |
See L<http://www.learning-perl.com/2015/06/learning-perl-challenge-be-better-than-quorum/> | |
I went for baroqueness with this one. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env perl | |
use v5.20; | |
=for commentary | |
See L<http://www.learning-perl.com/2015/06/learning-perl-challenge-be-better-than-quorum/> | |
I know there will be reasonable entries, so here's one for variety ;-) | |
-- Sinan |
NewerOlder