Skip to content

Instantly share code, notes, and snippets.

while read a; do
curl -s $a |
tr -d '\n' |
sed -e 's/.*<title>//'
-e 's/<\/title>.*//'
-e 's/^ *//'
-e 's/ *$//'
-e 's/$/:/'
echo
echo $a
/show_grid {
/Times-Italic findfont 8 scalefont setfont
matrix defaultmatrix setmatrix
0.1 setlinewidth
-2000 10 2000 {
/i exch def
-2000 i moveto 4000 0 rlineto
tr , '\n' |
sed -e 's/^ *//' |
awk '{print "\" "$0"=\" << "$0" << "}' |
sed -e 's/$/'\'' '\'' <</' -e 's/" /"/'
sed -e 's/^/std::cin, /' -e 's/,/ >>/g' -e 's/$/;/'
tr , '\n' |
sed -e 's/^ *//' |
awk '{print "\" "$0"=\" << "$0" << "}' |
tr -d '\n' |
sed -e 's/^/std::cerr << /' -e 's/$/std::endl;/' -e 's/" /"/'
tr , '\n' |
sed -e 's/^ *//' |
awk '{print $0" << '\'" "\'' << "}' |
tr -d '\n' |
sed -e 's/^/std::cout << /' -e 's/'\'' '\'' << $/std::endl;/'
(function () {
$('#choices .list_thumb').parent().parent().parent('.action_item').each(function() {
if ($(this).hasClass('selected_item'))
return;
this.click();
});
})();
(function () {
var ids = {};
$('#choices .action_item .status a').each(function () {
var href = $(this).attr('href');
if (! href)
return;
if (href.match(/https?:\/\/twitter.com\/[^/]+\//))
(function () {
var url = location.href;
if (! url.match(/beta/)) {
var a = url.split('/'), b = a[2].split('.');
location.href = 'https://beta.atcoder.jp/contests/' + b[0] + '/tasks/' + a[a.length - 1];
}
else {
var a = url.split('/'), b = a[2].split('.');
(function () {
$(".create_btn").click();
})();