This file contains hidden or 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 strict; | |
use warnings; | |
use Getopt::Long; | |
use List::Util qw/shuffle/; | |
my $n = 2; | |
my $count = 1; | |
my $nickfile; |
This file contains hidden or 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 strict; | |
use warnings; | |
use Getopt::Long; | |
local $\ = "\n"; | |
my %target; |
This file contains hidden or 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 | |
my $wc = 0; | |
my @ignore = ('Abstract'); | |
my $ig_pat = join '|', @ignore; | |
while (<>) { | |
/\\section\*?{(?:$ig_pat)}/ .. /\\section\*?{(?!:$ig_pat)}/ && next; | |
/\\begin{lstlisting}/ .. /\\end{lstlisting}/ && next; |
This file contains hidden or 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 <stdio.h> | |
#include <assert.h> | |
int main() | |
{ | |
const char *myfifo = "/var/myfifo"; | |
FILE *fifoin = fopen(myfifo, "r");; | |
int c; | |
assert(fifoin); |
This file contains hidden or 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 <stdio.h> | |
#include <stdint.h> | |
static int palindromic(uint64_t x) | |
{ | |
uint64_t rev = 0; | |
for (uint64_t tmp = x; tmp; tmp /= 10) { | |
rev *= 10; | |
rev += tmp % 10; | |
} |
This file contains hidden or 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 <stdio.h> | |
#include <stdint.h> | |
static int palindromic(uint64_t x) | |
{ | |
/* C version for reference | |
uint64_t rev = 0; | |
for (uint64_t tmp = x; tmp; tmp /= 10) { | |
rev *= 10; | |
rev += tmp % 10; |