#!/usr/bin/perl
use strict;
use warnings;
use feature qw/ say /;
my $first = ( split ',', <DATA> )[0];
say $first;
__DATA__
1424621700, 2015-02-22 16:15:00, 4294.700
1424621760, 2015-02-22 16:16:00, 4289.700
1424621820, 2015-02-22 16:17:00, 4299.800
1424621880, 2015-02-22 16:18:00, 4302.800
1424621940, 2015-02-22 16:19:00, 4296.900
1424622000, 2015-02-22 16:20:00, 4301.000
1424622060, 2015-02-22 16:21:00, 4300.300
$ perl 1140499.pl
1424621700
$
++james28909 for making me see it more simply.
The way forward always starts with a minimal test.
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.