Sha256: c79f02947c5bf5d5552a0aaa4d7473b5c0bfb6674068619fad5622f577b84b12

Contents?: true

Size: 504 Bytes

Versions: 82

Compression:

Stored size: 504 Bytes

Contents

exercise: Phone
version: 3
plan: 14
imports: '&clean-number'
tests: |
  for @($c-data<cases>[0]<cases>) {
    if .<expected> {
      is clean-number(.<phrase>), |.<expected description>;
    } else {
      nok clean-number(.<phrase>), .<description>;
    }
  }

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

Version data entries

82 entries across 82 versions & 1 rubygems

Version Path
trackler-2.2.1.33 tracks/perl6/exercises/phone-number/example.yaml
trackler-2.2.1.32 tracks/perl6/exercises/phone-number/example.yaml
trackler-2.2.1.31 tracks/perl6/exercises/phone-number/example.yaml
trackler-2.2.1.30 tracks/perl6/exercises/phone-number/example.yaml
trackler-2.2.1.29 tracks/perl6/exercises/phone-number/example.yaml
trackler-2.2.1.28 tracks/perl6/exercises/phone-number/example.yaml
trackler-2.2.1.27 tracks/perl6/exercises/phone-number/example.yaml
trackler-2.2.1.26 tracks/perl6/exercises/phone-number/example.yaml
trackler-2.2.1.25 tracks/perl6/exercises/phone-number/example.yaml
trackler-2.2.1.24 tracks/perl6/exercises/phone-number/example.yaml
trackler-2.2.1.23 tracks/perl6/exercises/phone-number/example.yaml
trackler-2.2.1.22 tracks/perl6/exercises/phone-number/example.yaml
trackler-2.2.1.21 tracks/perl6/exercises/phone-number/example.yaml
trackler-2.2.1.20 tracks/perl6/exercises/phone-number/example.yaml
trackler-2.2.1.19 tracks/perl6/exercises/phone-number/example.yaml
trackler-2.2.1.18 tracks/perl6/exercises/phone-number/example.yaml
trackler-2.2.1.17 tracks/perl6/exercises/phone-number/example.yaml
trackler-2.2.1.16 tracks/perl6/exercises/phone-number/example.yaml
trackler-2.2.1.15 tracks/perl6/exercises/phone-number/example.yaml
trackler-2.2.1.14 tracks/perl6/exercises/phone-number/example.yaml