Skip to content

Instantly share code, notes, and snippets.

View kyuu1999's full-sized avatar

Yuu Kaneda kyuu1999

  • japan
View GitHub Profile
@kyuu1999
kyuu1999 / gomafes4.pl
Created November 2, 2015 02:46
プルメリアをめっちゃ走らせる
use strict;
use warnings;
use feature qw/say/;
use HTTP::Request::Common;
use LWP::UserAgent;
use Time::HiRes;
use JSON;
my $ua = LWP::UserAgent->new;
my (@price,@day);
<STDIN> =~ /(\d+) (\d+)/;
$price[$_] = <STDIN> for (0..($1-1));
$day[$_] = <STDIN> for (0..($2-1));
@price = sort {$a <=> $b} @price;
for my $setprice (@day){
my @tmp = grep { $_ <= $setprice - $price[0] } @price;
my $check = 0;