SlideShare uma empresa Scribd logo
1 de 48
YAPC::Tiny
             Thanks for Coming!




tags: yapctiny, taichung   #chupei.pm freenode
Today’s Talks
    gugod                                /   Perl
 nothingmuch        1. Try::Tiny, 2.Continuation::Delimited
    shelling       Beautify code through extending module
      Ijs                        Jifty
     clkao                    Trading with Perl
    ihower             key-value store (TokyoCabinet)
St. Keven (zard)
    imacat


    penkia


    BlueT
      c9s
long long time_t ago ...
shell script




ps -e | wc | expand | sed
-e s/    /:/g | awk -
F":" '{ print $2 }'
Larry Wall
Father of Perl
Just Perl It!




  Larry Wall
Father of Perl
!$@%&*




  Larry Wall
Father of Perl
Version      Date
1.000     1987-Dec-18
2.000     1988-Jun-05
3.000     1989-Oct-18
4.000     1991-Mar-21
5.000     1994-Oct-17
 5.6.0    1995-Mar-13
 5.8.0     2002-Jul-18
 5.9.0    2003-Oct-27
5.10.0    2007-Dec-18
5.10.1    2009-Aug-22
Version      Date
      1.000     1987-Dec-18
      2.000     1988-Jun-05
      3.000     1989-Oct-18
      4.000     1991-Mar-21
      5.000     1994-Oct-17
       5.6.0    1995-Mar-13
       5.8.0     2002-Jul-18
       5.9.0    2003-Oct-27
20y   5.10.0    2007-Dec-18
      5.10.1    2009-Aug-22
Perl 5: The Big Nouns
•   Compatibility   •   Maintainability

•   Extensibility   •   Portability

•   Usability       •   Responsibility

•   Reusability     •   Embeddibility

•   Readability     •   Respectability?

•   Scalability
Perl 6
@a »+« @b
• pugs http://pugscode.org
• rakudo http://rakudo.org/
Modern Perl
    Perl5
Modern Sense
Best Practices
Damian
Conway
Damian
Conway
Clear Semantic
  Trivial to Understand
Moose




Postmodern OO /
package Point;
use Moose;

has 'x' => (is => 'rw', isa => 'Int');
has 'y' => (is => 'rw', isa => 'Int');

sub clear {
  my $self = shift;
  $self->x(0);
  $self->y(0);
}
package Point3D;
use Moose;

extends 'Point';

has 'z' => (is => 'rw', isa => 'Int');

after 'clear' => sub {
   my $self = shift;
   $self->z(0);
};
package Point3D;
use Moose;

extends 'Point';

has 'z' => (is => 'rw', isa => 'Int');

after 'clear' => sub {
   my $self = shift;
   $self->z(0);
};
package Point3D;
use Moose;

extends 'Point';

has 'z' => (is => 'rw', isa => 'Int');

after 'clear' => sub {
   my $self = shift;
   $self->z(0);
};
package Point3D;
use Moose;

extends 'Point';

has 'z' => (is => 'rw', isa => 'Int');

after 'clear' => sub {
   my $self = shift;
   $self->z(0);
};
use MooseX::Declare;

class Point {
   has 'x' => (is => 'rw', isa => 'Int');
   has 'y' => (is => 'rw', isa => 'Int');

    method clear {
      $self->x(0);
      $self->y(0);
    }
}
Extendibility
Self-Modifying Perl
App->start {
    say "Hello";
 };


Not-really valid Perl5
App->start(sub {
    say "Hello";
});


   Valid Perl5
WHY ?


•   / Augmented Syntax

•   / Extended Semantic
As a modern Perl
 programmer...
        Perl
We Learn Perl
We Learn Perl
We Write Perl
perl -MTime::JulianDay -lwe'@r=reverse(M=>(0)x99=>CM=>(0)x399=>D=>(0)x99=>CD=>(
0)x299=>C=>(0)x9=>XC=>(0)x39=>L=>(0)x9=>XL=>(0)x29=>X=>IX=>0=>0=>0=>V=>IV=
>0=>0
=>I=>$==-2449231+gm_julian_day+time);do{until($=<$#r){$_.=$r[$#r];$=-=$#r}for(;
!$r[--$#r];){}}while$=;$,="x20";print+$_=>September=>MCMXCIII=>=>=>=>=>=>=>=>'
#!/usr/bin/perl -w                   # camel code
use strict;

                                $_='ev
                             al("seek040D
         ATA,0,              0;");foreach(1..3)
      {<DATA>;}my                @camel1hump;my$camel;
  my$Camel ;while(              <DATA>){$_=sprintf("%-6
9s",$_);my@dromedary               1=split(//);if(defined($
_=<DATA>)){@camel1hum                p=split(//);}while(@dromeda
 ry1){my$camel1hump=0             ;my$CAMEL=3;if(defined($_=shif
       t(@dromedary1 ))&&/S/){$camel1hump+=1<<$CAMEL;}
      $CAMEL--;if(d efined($_=shift(@dromedary1))&&/S/){
     $camel1hump+=1 <<$CAMEL;}$CAMEL--;if(defined($_=shift(
    @camel1hump))&&/S/){$camel1hump+=1<<$CAMEL;}$CAMEL--;if(
    defined($_=shift(@camel1hump))&&/S/){$camel1hump+=1<<$CAME
    L;;}$camel.=(split(//,"040..m`{/J047134}L^7FX"))[$camel1h
     ump];}$camel.="n";}@camel1hump=split(/n/,$camel);foreach(@
     camel1hump){chomp;$Camel=$_;y/LJF7173175`047/061062063
     064065066067070/;y/12345678/JL7F175173047`/;$_=reverse;
      print"$_040$Cameln";}foreach(@camel1hump){chomp;$Camel=$_;y
       /LJF7173175`047/12345678/;y/12345678/JL7F1751730 47`/;
        $_=reverse;print"040$_$Cameln";}';;s/s*//g;;eval; eval
         ("seek040DATA,0,0;");undef$/;$_=<DATA>;s/s*//g;( );;s
           ;^.*_;;;map{eval"print"$_"";}/.{4}/g; __DATA__ 124
             1 501450401651631450401571 460401 410
                40143141 1551451 540401 51155 141
                1471450 40151156 040141 16316 3
                 157143 15114116 41511              57156
                 040167 1511641 50040              1201
                 45162 15404015 1163               04014
                 10401 641621          41144        145
                 15514 1162          15304         0157
                  146   04011       7047         1221
                  4515     11541 54171             040
                  046       01210116             316
                  315        714315             114
                  116         4145163            054
                 040         11115614           3056
                040       12516314514             4040
                1671       511641 500            40160
               145162                       155151
              163163                        1511
            57156056
We Promote Perl
    http://www.pm.org/
   http://chupei.pm.org/
We Rock Perl
       YAPC 10 years
      http://yapc.org/
 http://yapc.asia/ (     )
We Extend Perl
We &heart; Perl
We &heart; Perl
Thanks for Listening

Mais conteúdo relacionado

Mais procurados

Good Evils In Perl
Good Evils In PerlGood Evils In Perl
Good Evils In Perl
Kang-min Liu
 
Vim Script Programming
Vim Script ProgrammingVim Script Programming
Vim Script Programming
Lin Yo-An
 
Good Evils In Perl (Yapc Asia)
Good Evils In Perl (Yapc Asia)Good Evils In Perl (Yapc Asia)
Good Evils In Perl (Yapc Asia)
Kang-min Liu
 

Mais procurados (19)

Perl dancer
Perl dancerPerl dancer
Perl dancer
 
I, For One, Welcome Our New Perl6 Overlords
I, For One, Welcome Our New Perl6 OverlordsI, For One, Welcome Our New Perl6 Overlords
I, For One, Welcome Our New Perl6 Overlords
 
Perl Moderno
Perl ModernoPerl Moderno
Perl Moderno
 
Good Evils In Perl
Good Evils In PerlGood Evils In Perl
Good Evils In Perl
 
Vim Script Programming
Vim Script ProgrammingVim Script Programming
Vim Script Programming
 
Vim Hacks
Vim HacksVim Hacks
Vim Hacks
 
Follow the White Rabbit - Message Queues with PHP
Follow the White Rabbit - Message Queues with PHPFollow the White Rabbit - Message Queues with PHP
Follow the White Rabbit - Message Queues with PHP
 
Discovering functional treasure in idiomatic Groovy
Discovering functional treasure in idiomatic GroovyDiscovering functional treasure in idiomatic Groovy
Discovering functional treasure in idiomatic Groovy
 
Shell Script
Shell ScriptShell Script
Shell Script
 
Ruby 1.9
Ruby 1.9Ruby 1.9
Ruby 1.9
 
PHPerのためのPerl入門@ Kansai.pm#12
PHPerのためのPerl入門@ Kansai.pm#12PHPerのためのPerl入門@ Kansai.pm#12
PHPerのためのPerl入門@ Kansai.pm#12
 
Modern Getopt for Command Line Processing in Perl
Modern Getopt for Command Line Processing in PerlModern Getopt for Command Line Processing in Perl
Modern Getopt for Command Line Processing in Perl
 
Perl 6 by example
Perl 6 by examplePerl 6 by example
Perl 6 by example
 
Rubinius - A Tool of the Future
Rubinius - A Tool of the FutureRubinius - A Tool of the Future
Rubinius - A Tool of the Future
 
Unix shell scripting
Unix shell scriptingUnix shell scripting
Unix shell scripting
 
The promise of asynchronous php
The promise of asynchronous phpThe promise of asynchronous php
The promise of asynchronous php
 
Good Evils In Perl (Yapc Asia)
Good Evils In Perl (Yapc Asia)Good Evils In Perl (Yapc Asia)
Good Evils In Perl (Yapc Asia)
 
Crystal: Fundamentos, objetivos y desafios - Cacic 2019
Crystal: Fundamentos, objetivos y desafios - Cacic 2019Crystal: Fundamentos, objetivos y desafios - Cacic 2019
Crystal: Fundamentos, objetivos y desafios - Cacic 2019
 
Happy Go Programming
Happy Go ProgrammingHappy Go Programming
Happy Go Programming
 

Destaque (7)

Ppoint blog
Ppoint blogPpoint blog
Ppoint blog
 
Git
GitGit
Git
 
SQL Server Managing Test Data & Stress Testing January 2011
SQL Server Managing Test Data & Stress Testing January 2011SQL Server Managing Test Data & Stress Testing January 2011
SQL Server Managing Test Data & Stress Testing January 2011
 
Perlbrew
PerlbrewPerlbrew
Perlbrew
 
perlbrew yapcasia 2010
perlbrew yapcasia 2010perlbrew yapcasia 2010
perlbrew yapcasia 2010
 
Same but Different
Same but DifferentSame but Different
Same but Different
 
Elasticsearch 實戰介紹
Elasticsearch 實戰介紹Elasticsearch 實戰介紹
Elasticsearch 實戰介紹
 

Semelhante a YAPC::Tiny Introduction

Migrating To Ruby1.9
Migrating To Ruby1.9Migrating To Ruby1.9
Migrating To Ruby1.9
tomaspavelka
 

Semelhante a YAPC::Tiny Introduction (20)

What's new in Perl 5.10?
What's new in Perl 5.10?What's new in Perl 5.10?
What's new in Perl 5.10?
 
2016年のPerl (Long version)
2016年のPerl (Long version)2016年のPerl (Long version)
2016年のPerl (Long version)
 
The $path to knowledge: What little it take to unit-test Perl.
The $path to knowledge: What little it take to unit-test Perl.The $path to knowledge: What little it take to unit-test Perl.
The $path to knowledge: What little it take to unit-test Perl.
 
Cleanliness is Next to Domain-Specificity
Cleanliness is Next to Domain-SpecificityCleanliness is Next to Domain-Specificity
Cleanliness is Next to Domain-Specificity
 
Cleanliness is Next to Domain-Specificity
Cleanliness is Next to Domain-SpecificityCleanliness is Next to Domain-Specificity
Cleanliness is Next to Domain-Specificity
 
Perl basics for Pentesters
Perl basics for PentestersPerl basics for Pentesters
Perl basics for Pentesters
 
Whatsnew in-perl
Whatsnew in-perlWhatsnew in-perl
Whatsnew in-perl
 
Modern Perl
Modern PerlModern Perl
Modern Perl
 
Perl - laziness, impatience, hubris, and one liners
Perl - laziness, impatience, hubris, and one linersPerl - laziness, impatience, hubris, and one liners
Perl - laziness, impatience, hubris, and one liners
 
Bash tricks
Bash tricksBash tricks
Bash tricks
 
Dealing with Legacy Perl Code - Peter Scott
Dealing with Legacy Perl Code - Peter ScottDealing with Legacy Perl Code - Peter Scott
Dealing with Legacy Perl Code - Peter Scott
 
Performance Wins with BPF: Getting Started
Performance Wins with BPF: Getting StartedPerformance Wins with BPF: Getting Started
Performance Wins with BPF: Getting Started
 
Migrating To Ruby1.9
Migrating To Ruby1.9Migrating To Ruby1.9
Migrating To Ruby1.9
 
Being functional in PHP (PHPDay Italy 2016)
Being functional in PHP (PHPDay Italy 2016)Being functional in PHP (PHPDay Italy 2016)
Being functional in PHP (PHPDay Italy 2016)
 
Anacronia on speed
Anacronia on speedAnacronia on speed
Anacronia on speed
 
Actor Concurrency
Actor ConcurrencyActor Concurrency
Actor Concurrency
 
What's new in Puppet 3.0
What's new in Puppet 3.0What's new in Puppet 3.0
What's new in Puppet 3.0
 
Regular Expressions: Backtracking, and The Little Engine that Could(n't)?
Regular Expressions: Backtracking, and The Little Engine that Could(n't)?Regular Expressions: Backtracking, and The Little Engine that Could(n't)?
Regular Expressions: Backtracking, and The Little Engine that Could(n't)?
 
Yapc::NA::2009 - Command Line Perl
Yapc::NA::2009 - Command Line PerlYapc::NA::2009 - Command Line Perl
Yapc::NA::2009 - Command Line Perl
 
Perl Presentation
Perl PresentationPerl Presentation
Perl Presentation
 

Mais de Kang-min Liu (11)

o̍h Tai-gi
o̍h Tai-gio̍h Tai-gi
o̍h Tai-gi
 
The architecture of search engines in Booking.com
The architecture of search engines in Booking.comThe architecture of search engines in Booking.com
The architecture of search engines in Booking.com
 
Integration Test With Cucumber And Webrat
Integration Test With Cucumber And WebratIntegration Test With Cucumber And Webrat
Integration Test With Cucumber And Webrat
 
Javascript Tutorial
Javascript TutorialJavascript Tutorial
Javascript Tutorial
 
Javascript Basic
Javascript BasicJavascript Basic
Javascript Basic
 
Handlino - RandomLife
Handlino - RandomLifeHandlino - RandomLife
Handlino - RandomLife
 
Jformino
JforminoJformino
Jformino
 
Test Continuous
Test ContinuousTest Continuous
Test Continuous
 
網頁程式還可以怎麼設計
網頁程式還可以怎麼設計網頁程式還可以怎麼設計
網頁程式還可以怎麼設計
 
OSDC.tw 2008 Lightening Talk
OSDC.tw 2008 Lightening TalkOSDC.tw 2008 Lightening Talk
OSDC.tw 2008 Lightening Talk
 
Happy Designer 20080329
Happy Designer 20080329Happy Designer 20080329
Happy Designer 20080329
 

Último

The Abortion pills for sale in Qatar@Doha [+27737758557] []Deira Dubai Kuwait
The Abortion pills for sale in Qatar@Doha [+27737758557] []Deira Dubai KuwaitThe Abortion pills for sale in Qatar@Doha [+27737758557] []Deira Dubai Kuwait
The Abortion pills for sale in Qatar@Doha [+27737758557] []Deira Dubai Kuwait
daisycvs
 
obat aborsi bandung wa 081336238223 jual obat aborsi cytotec asli di bandung9...
obat aborsi bandung wa 081336238223 jual obat aborsi cytotec asli di bandung9...obat aborsi bandung wa 081336238223 jual obat aborsi cytotec asli di bandung9...
obat aborsi bandung wa 081336238223 jual obat aborsi cytotec asli di bandung9...
yulianti213969
 
Al Mizhar Dubai Escorts +971561403006 Escorts Service In Al Mizhar
Al Mizhar Dubai Escorts +971561403006 Escorts Service In Al MizharAl Mizhar Dubai Escorts +971561403006 Escorts Service In Al Mizhar
Al Mizhar Dubai Escorts +971561403006 Escorts Service In Al Mizhar
allensay1
 

Último (20)

The Abortion pills for sale in Qatar@Doha [+27737758557] []Deira Dubai Kuwait
The Abortion pills for sale in Qatar@Doha [+27737758557] []Deira Dubai KuwaitThe Abortion pills for sale in Qatar@Doha [+27737758557] []Deira Dubai Kuwait
The Abortion pills for sale in Qatar@Doha [+27737758557] []Deira Dubai Kuwait
 
Katrina Personal Brand Project and portfolio 1
Katrina Personal Brand Project and portfolio 1Katrina Personal Brand Project and portfolio 1
Katrina Personal Brand Project and portfolio 1
 
Call 7737669865 Vadodara Call Girls Service at your Door Step Available All Time
Call 7737669865 Vadodara Call Girls Service at your Door Step Available All TimeCall 7737669865 Vadodara Call Girls Service at your Door Step Available All Time
Call 7737669865 Vadodara Call Girls Service at your Door Step Available All Time
 
Marel Q1 2024 Investor Presentation from May 8, 2024
Marel Q1 2024 Investor Presentation from May 8, 2024Marel Q1 2024 Investor Presentation from May 8, 2024
Marel Q1 2024 Investor Presentation from May 8, 2024
 
Buy gmail accounts.pdf buy Old Gmail Accounts
Buy gmail accounts.pdf buy Old Gmail AccountsBuy gmail accounts.pdf buy Old Gmail Accounts
Buy gmail accounts.pdf buy Old Gmail Accounts
 
KALYANI 💋 Call Girl 9827461493 Call Girls in Escort service book now
KALYANI 💋 Call Girl 9827461493 Call Girls in  Escort service book nowKALYANI 💋 Call Girl 9827461493 Call Girls in  Escort service book now
KALYANI 💋 Call Girl 9827461493 Call Girls in Escort service book now
 
Nanded Call Girl Just Call 8084732287 Top Class Call Girl Service Available
Nanded Call Girl Just Call 8084732287 Top Class Call Girl Service AvailableNanded Call Girl Just Call 8084732287 Top Class Call Girl Service Available
Nanded Call Girl Just Call 8084732287 Top Class Call Girl Service Available
 
Arti Languages Pre Seed Teaser Deck 2024.pdf
Arti Languages Pre Seed Teaser Deck 2024.pdfArti Languages Pre Seed Teaser Deck 2024.pdf
Arti Languages Pre Seed Teaser Deck 2024.pdf
 
Putting the SPARK into Virtual Training.pptx
Putting the SPARK into Virtual Training.pptxPutting the SPARK into Virtual Training.pptx
Putting the SPARK into Virtual Training.pptx
 
Berhampur CALL GIRL❤7091819311❤CALL GIRLS IN ESCORT SERVICE WE ARE PROVIDING
Berhampur CALL GIRL❤7091819311❤CALL GIRLS IN ESCORT SERVICE WE ARE PROVIDINGBerhampur CALL GIRL❤7091819311❤CALL GIRLS IN ESCORT SERVICE WE ARE PROVIDING
Berhampur CALL GIRL❤7091819311❤CALL GIRLS IN ESCORT SERVICE WE ARE PROVIDING
 
Lundin Gold - Q1 2024 Conference Call Presentation (Revised)
Lundin Gold - Q1 2024 Conference Call Presentation (Revised)Lundin Gold - Q1 2024 Conference Call Presentation (Revised)
Lundin Gold - Q1 2024 Conference Call Presentation (Revised)
 
Escorts in Nungambakkam Phone 8250092165 Enjoy 24/7 Escort Service Enjoy Your...
Escorts in Nungambakkam Phone 8250092165 Enjoy 24/7 Escort Service Enjoy Your...Escorts in Nungambakkam Phone 8250092165 Enjoy 24/7 Escort Service Enjoy Your...
Escorts in Nungambakkam Phone 8250092165 Enjoy 24/7 Escort Service Enjoy Your...
 
obat aborsi bandung wa 081336238223 jual obat aborsi cytotec asli di bandung9...
obat aborsi bandung wa 081336238223 jual obat aborsi cytotec asli di bandung9...obat aborsi bandung wa 081336238223 jual obat aborsi cytotec asli di bandung9...
obat aborsi bandung wa 081336238223 jual obat aborsi cytotec asli di bandung9...
 
Only Cash On Delivery Call Girls In Sikandarpur Gurgaon ❤️8448577510 ⊹Escorts...
Only Cash On Delivery Call Girls In Sikandarpur Gurgaon ❤️8448577510 ⊹Escorts...Only Cash On Delivery Call Girls In Sikandarpur Gurgaon ❤️8448577510 ⊹Escorts...
Only Cash On Delivery Call Girls In Sikandarpur Gurgaon ❤️8448577510 ⊹Escorts...
 
Berhampur 70918*19311 CALL GIRLS IN ESCORT SERVICE WE ARE PROVIDING
Berhampur 70918*19311 CALL GIRLS IN ESCORT SERVICE WE ARE PROVIDINGBerhampur 70918*19311 CALL GIRLS IN ESCORT SERVICE WE ARE PROVIDING
Berhampur 70918*19311 CALL GIRLS IN ESCORT SERVICE WE ARE PROVIDING
 
Uneak White's Personal Brand Exploration Presentation
Uneak White's Personal Brand Exploration PresentationUneak White's Personal Brand Exploration Presentation
Uneak White's Personal Brand Exploration Presentation
 
Phases of Negotiation .pptx
 Phases of Negotiation .pptx Phases of Negotiation .pptx
Phases of Negotiation .pptx
 
Al Mizhar Dubai Escorts +971561403006 Escorts Service In Al Mizhar
Al Mizhar Dubai Escorts +971561403006 Escorts Service In Al MizharAl Mizhar Dubai Escorts +971561403006 Escorts Service In Al Mizhar
Al Mizhar Dubai Escorts +971561403006 Escorts Service In Al Mizhar
 
Unveiling Falcon Invoice Discounting: Leading the Way as India's Premier Bill...
Unveiling Falcon Invoice Discounting: Leading the Way as India's Premier Bill...Unveiling Falcon Invoice Discounting: Leading the Way as India's Premier Bill...
Unveiling Falcon Invoice Discounting: Leading the Way as India's Premier Bill...
 
Berhampur Call Girl Just Call 8084732287 Top Class Call Girl Service Available
Berhampur Call Girl Just Call 8084732287 Top Class Call Girl Service AvailableBerhampur Call Girl Just Call 8084732287 Top Class Call Girl Service Available
Berhampur Call Girl Just Call 8084732287 Top Class Call Girl Service Available
 

YAPC::Tiny Introduction

  • 1. YAPC::Tiny Thanks for Coming! tags: yapctiny, taichung #chupei.pm freenode
  • 2. Today’s Talks gugod / Perl nothingmuch 1. Try::Tiny, 2.Continuation::Delimited shelling Beautify code through extending module Ijs Jifty clkao Trading with Perl ihower key-value store (TokyoCabinet) St. Keven (zard) imacat penkia BlueT c9s
  • 3.
  • 5. shell script ps -e | wc | expand | sed -e s/ /:/g | awk - F":" '{ print $2 }'
  • 6.
  • 8. Just Perl It! Larry Wall Father of Perl
  • 9. !$@%&* Larry Wall Father of Perl
  • 10. Version Date 1.000 1987-Dec-18 2.000 1988-Jun-05 3.000 1989-Oct-18 4.000 1991-Mar-21 5.000 1994-Oct-17 5.6.0 1995-Mar-13 5.8.0 2002-Jul-18 5.9.0 2003-Oct-27 5.10.0 2007-Dec-18 5.10.1 2009-Aug-22
  • 11. Version Date 1.000 1987-Dec-18 2.000 1988-Jun-05 3.000 1989-Oct-18 4.000 1991-Mar-21 5.000 1994-Oct-17 5.6.0 1995-Mar-13 5.8.0 2002-Jul-18 5.9.0 2003-Oct-27 20y 5.10.0 2007-Dec-18 5.10.1 2009-Aug-22
  • 12.
  • 13.
  • 14. Perl 5: The Big Nouns • Compatibility • Maintainability • Extensibility • Portability • Usability • Responsibility • Reusability • Embeddibility • Readability • Respectability? • Scalability
  • 16. • pugs http://pugscode.org • rakudo http://rakudo.org/
  • 17.
  • 18. Modern Perl Perl5
  • 21.
  • 24. Clear Semantic Trivial to Understand
  • 25.
  • 27. package Point; use Moose; has 'x' => (is => 'rw', isa => 'Int'); has 'y' => (is => 'rw', isa => 'Int'); sub clear { my $self = shift; $self->x(0); $self->y(0); }
  • 28. package Point3D; use Moose; extends 'Point'; has 'z' => (is => 'rw', isa => 'Int'); after 'clear' => sub { my $self = shift; $self->z(0); };
  • 29. package Point3D; use Moose; extends 'Point'; has 'z' => (is => 'rw', isa => 'Int'); after 'clear' => sub { my $self = shift; $self->z(0); };
  • 30. package Point3D; use Moose; extends 'Point'; has 'z' => (is => 'rw', isa => 'Int'); after 'clear' => sub { my $self = shift; $self->z(0); };
  • 31. package Point3D; use Moose; extends 'Point'; has 'z' => (is => 'rw', isa => 'Int'); after 'clear' => sub { my $self = shift; $self->z(0); };
  • 32. use MooseX::Declare; class Point { has 'x' => (is => 'rw', isa => 'Int'); has 'y' => (is => 'rw', isa => 'Int'); method clear { $self->x(0); $self->y(0); } }
  • 35. App->start { say "Hello"; }; Not-really valid Perl5
  • 36. App->start(sub { say "Hello"; }); Valid Perl5
  • 37. WHY ? • / Augmented Syntax • / Extended Semantic
  • 38. As a modern Perl programmer... Perl
  • 41. We Write Perl perl -MTime::JulianDay -lwe'@r=reverse(M=>(0)x99=>CM=>(0)x399=>D=>(0)x99=>CD=>( 0)x299=>C=>(0)x9=>XC=>(0)x39=>L=>(0)x9=>XL=>(0)x29=>X=>IX=>0=>0=>0=>V=>IV= >0=>0 =>I=>$==-2449231+gm_julian_day+time);do{until($=<$#r){$_.=$r[$#r];$=-=$#r}for(; !$r[--$#r];){}}while$=;$,="x20";print+$_=>September=>MCMXCIII=>=>=>=>=>=>=>=>'
  • 42. #!/usr/bin/perl -w # camel code use strict; $_='ev al("seek040D ATA,0, 0;");foreach(1..3) {<DATA>;}my @camel1hump;my$camel; my$Camel ;while( <DATA>){$_=sprintf("%-6 9s",$_);my@dromedary 1=split(//);if(defined($ _=<DATA>)){@camel1hum p=split(//);}while(@dromeda ry1){my$camel1hump=0 ;my$CAMEL=3;if(defined($_=shif t(@dromedary1 ))&&/S/){$camel1hump+=1<<$CAMEL;} $CAMEL--;if(d efined($_=shift(@dromedary1))&&/S/){ $camel1hump+=1 <<$CAMEL;}$CAMEL--;if(defined($_=shift( @camel1hump))&&/S/){$camel1hump+=1<<$CAMEL;}$CAMEL--;if( defined($_=shift(@camel1hump))&&/S/){$camel1hump+=1<<$CAME L;;}$camel.=(split(//,"040..m`{/J047134}L^7FX"))[$camel1h ump];}$camel.="n";}@camel1hump=split(/n/,$camel);foreach(@ camel1hump){chomp;$Camel=$_;y/LJF7173175`047/061062063 064065066067070/;y/12345678/JL7F175173047`/;$_=reverse; print"$_040$Cameln";}foreach(@camel1hump){chomp;$Camel=$_;y /LJF7173175`047/12345678/;y/12345678/JL7F1751730 47`/; $_=reverse;print"040$_$Cameln";}';;s/s*//g;;eval; eval ("seek040DATA,0,0;");undef$/;$_=<DATA>;s/s*//g;( );;s ;^.*_;;;map{eval"print"$_"";}/.{4}/g; __DATA__ 124 1 501450401651631450401571 460401 410 40143141 1551451 540401 51155 141 1471450 40151156 040141 16316 3 157143 15114116 41511 57156 040167 1511641 50040 1201 45162 15404015 1163 04014 10401 641621 41144 145 15514 1162 15304 0157 146 04011 7047 1221 4515 11541 54171 040 046 01210116 316 315 714315 114 116 4145163 054 040 11115614 3056 040 12516314514 4040 1671 511641 500 40160 145162 155151 163163 1511 57156056
  • 43. We Promote Perl http://www.pm.org/ http://chupei.pm.org/
  • 44. We Rock Perl YAPC 10 years http://yapc.org/ http://yapc.asia/ ( )