Sha256: 8bfbc43c087f0a86de635980d2ed9bb3420cce33b7ed7f86d4938720b38c5b12

Contents?: true

Size: 184 Bytes

Versions: 148

Compression:

Stored size: 184 Bytes

Contents

unit module Phone:ver<3>;

sub clean-number ($number is copy) is export {
  $number ~~ s:g/<:!Nd>//;
  $number ~~ /^ 1? ( [ <[2..9]> <:Nd> ** 2 ] ** 2 <:Nd> ** 4 ) $/ ?? ~$0 !! Nil;
}

Version data entries

148 entries across 148 versions & 1 rubygems

Version Path
trackler-2.2.1.55 tracks/perl6/exercises/phone-number/Example.pm6
trackler-2.2.1.54 tracks/perl6/exercises/phone-number/Example.pm6
trackler-2.2.1.53 tracks/perl6/exercises/phone-number/Example.pm6
trackler-2.2.1.52 tracks/perl6/exercises/phone-number/Example.pm6
trackler-2.2.1.51 tracks/perl6/exercises/phone-number/Example.pm6
trackler-2.2.1.50 tracks/perl6/exercises/phone-number/Example.pm6
trackler-2.2.1.49 tracks/perl6/exercises/phone-number/Example.pm6
trackler-2.2.1.48 tracks/perl6/exercises/phone-number/Example.pm6
trackler-2.2.1.47 tracks/perl6/exercises/phone-number/Example.pm6
trackler-2.2.1.46 tracks/perl6/exercises/phone-number/Example.pm6
trackler-2.2.1.45 tracks/perl6/exercises/phone-number/Example.pm6
trackler-2.2.1.44 tracks/perl6/exercises/phone-number/Example.pm6
trackler-2.2.1.43 tracks/perl6/exercises/phone-number/Example.pm6
trackler-2.2.1.42 tracks/perl6/exercises/phone-number/Example.pm6
trackler-2.2.1.41 tracks/perl6/exercises/phone-number/Example.pm6
trackler-2.2.1.40 tracks/perl6/exercises/phone-number/Example.pm6
trackler-2.2.1.39 tracks/perl6/exercises/phone-number/Example.pm6
trackler-2.2.1.38 tracks/perl6/exercises/phone-number/Example.pm6
trackler-2.2.1.37 tracks/perl6/exercises/phone-number/Example.pm6
trackler-2.2.1.36 tracks/perl6/exercises/phone-number/Example.pm6