From a904054800bab25f8620bb9d00716c5c006d712d Mon Sep 17 00:00:00 2001 From: Mohammad Sajid Anwar Date: Sun, 15 Sep 2024 09:26:30 +0100 Subject: - Added solutions by Santiago Leyva. - Added solutions by Ali Moradi. - Added solutions by Matthias Muth. - Added solutions by Peter Meszaros. --- challenge-283/santiago-leyva/perl/ch-01.pl | 55 --- challenge-283/santiago-leyva/perl/ch-02.pl | 59 --- challenge-283/santiago-leyva/perl/ch-1.pl | 55 +++ challenge-283/santiago-leyva/perl/ch-2.pl | 59 +++ challenge-284/santiago-leyva/perl/ch-01.pl | 56 --- challenge-284/santiago-leyva/perl/ch-02.pl | 86 ---- challenge-284/santiago-leyva/perl/ch-1.pl | 56 +++ challenge-284/santiago-leyva/perl/ch-2.pl | 86 ++++ challenge-285/santiago-leyva/perl/ch-01.pl | 58 --- challenge-285/santiago-leyva/perl/ch-02.pl | 66 --- challenge-285/santiago-leyva/perl/ch-1.pl | 58 +++ challenge-285/santiago-leyva/perl/ch-2.pl | 66 +++ stats/pwc-challenge-199.json | 317 ++++++------ stats/pwc-challenge-283.json | 273 ++++++----- stats/pwc-challenge-284.json | 589 +++++++++++----------- stats/pwc-challenge-285.json | 549 +++++++++++---------- stats/pwc-current.json | 400 ++++++++------- stats/pwc-language-breakdown-2019.json | 304 ++++++------ stats/pwc-language-breakdown-2020.json | 394 +++++++-------- stats/pwc-language-breakdown-2021.json | 376 +++++++------- stats/pwc-language-breakdown-2022.json | 758 ++++++++++++++--------------- stats/pwc-language-breakdown-2023.json | 378 +++++++------- stats/pwc-language-breakdown-2024.json | 282 +++++------ stats/pwc-language-breakdown-summary.json | 72 +-- stats/pwc-leaders.json | 394 +++++++-------- stats/pwc-summary-1-30.json | 50 +- stats/pwc-summary-121-150.json | 110 ++--- stats/pwc-summary-151-180.json | 112 ++--- stats/pwc-summary-181-210.json | 50 +- stats/pwc-summary-211-240.json | 36 +- stats/pwc-summary-241-270.json | 42 +- stats/pwc-summary-271-300.json | 52 +- stats/pwc-summary-301-330.json | 98 ++-- stats/pwc-summary-31-60.json | 42 +- stats/pwc-summary-61-90.json | 38 +- stats/pwc-summary-91-120.json | 52 +- stats/pwc-summary.json | 698 +++++++++++++------------- stats/pwc-yearly-language-summary.json | 144 +++--- 38 files changed, 3736 insertions(+), 3634 deletions(-) delete mode 100644 challenge-283/santiago-leyva/perl/ch-01.pl delete mode 100644 challenge-283/santiago-leyva/perl/ch-02.pl create mode 100644 challenge-283/santiago-leyva/perl/ch-1.pl create mode 100644 challenge-283/santiago-leyva/perl/ch-2.pl delete mode 100644 challenge-284/santiago-leyva/perl/ch-01.pl delete mode 100644 challenge-284/santiago-leyva/perl/ch-02.pl create mode 100644 challenge-284/santiago-leyva/perl/ch-1.pl create mode 100644 challenge-284/santiago-leyva/perl/ch-2.pl delete mode 100644 challenge-285/santiago-leyva/perl/ch-01.pl delete mode 100644 challenge-285/santiago-leyva/perl/ch-02.pl create mode 100644 challenge-285/santiago-leyva/perl/ch-1.pl create mode 100644 challenge-285/santiago-leyva/perl/ch-2.pl diff --git a/challenge-283/santiago-leyva/perl/ch-01.pl b/challenge-283/santiago-leyva/perl/ch-01.pl deleted file mode 100644 index 6431df3b2f..0000000000 --- a/challenge-283/santiago-leyva/perl/ch-01.pl +++ /dev/null @@ -1,55 +0,0 @@ -=begin -You are given an array of integers, @ints, where every elements appears more than once except one element. - -Write a script to find the one element that appears exactly one time. - -Example 1 -Input: @ints = (3, 3, 1) -Output: 1 -Example 2 -Input: @ints = (3, 2, 4, 2, 4) -Output: 3 -Example 3 -Input: @ints = (1) -Output: 1 -Example 4 -Input: @ints = (4, 3, 1, 1, 1, 4) -Output: 3 -=cut -use strict; -use Data::Dumper; - - -my @inputs = ([3, 3, 1],[3, 2, 4, 2, 4],[1],[4, 3, 1, 1, 1, 4]); - -foreach(@inputs){ - my $arr = $_; - my @A = @$arr; - my $result = findUnique(\@A); - print $result."\n"; -} - -sub findUnique { - my $array = shift; - my @nums = @$array; - my %seen; - my %deleted; - foreach(@nums){ - - if(exists($seen{$_})){ - $seen{$_} += 1; - $deleted{$_} = 1; - delete $seen{$_}; - }else{ - if(!exists($deleted{$_})){ - $seen{$_} = 1; - } - } - } - - my @values = keys %seen; - - return $values[0] if (@values); - return -1; - -} \ No newline at end of file diff --git a/challenge-283/santiago-leyva/perl/ch-02.pl b/challenge-283/santiago-leyva/perl/ch-02.pl deleted file mode 100644 index 30b7ab6879..0000000000 --- a/challenge-283/santiago-leyva/perl/ch-02.pl +++ /dev/null @@ -1,59 +0,0 @@ -=begin -You are given an array of positive integers, @ints. - -Write a script to return true if for every index i in the range 0 <= i < size of array, the digit i occurs exactly the $ints[$i] times in the given array otherwise return false. - -Example 1 -Input: @ints = (1, 2, 1, 0) -Ouput: true - -$ints[0] = 1, the digit 0 occurs exactly 1 time. -$ints[1] = 2, the digit 1 occurs exactly 2 times. -$ints[2] = 1, the digit 2 occurs exactly 1 time. -$ints[3] = 0, the digit 3 occurs 0 time. -Example 2 -Input: @ints = (0, 3, 0) -Ouput: false - -$ints[0] = 0, the digit 0 occurs 2 times rather than 0 time. -$ints[1] = 3, the digit 1 occurs 0 time rather than 3 times. -$ints[2] = 0, the digit 2 occurs exactly 0 time. -=cut -use strict; -use Data::Dumper; - - -my @inputs = ([1, 2, 1, 0],[0, 3, 0]); - -foreach(@inputs){ - my $arr = $_; - my @A = @$arr; - my $result = checkIndex(\@A); - print $result."\n"; -} - -sub checkIndex { - my $array = shift; - my @nums = @$array; - - my %seen; - my %deleted; - foreach(@nums){ - - if(exists($seen{$_})){ - $seen{$_} += 1; - }else{ - $seen{$_} = 1; - } - } - - my $i = 0; - foreach(@nums){ - if(!exists($seen{$i}) and $seen{$i} != $_){ - return 'false'; - } - $i++; - } - - return 'true'; -} \ No newline at end of file diff --git a/challenge-283/santiago-leyva/perl/ch-1.pl b/challenge-283/santiago-leyva/perl/ch-1.pl new file mode 100644 index 0000000000..6431df3b2f --- /dev/null +++ b/challenge-283/santiago-leyva/perl/ch-1.pl @@ -0,0 +1,55 @@ +=begin +You are given an array of integers, @ints, where every elements appears more than once except one element. + +Write a script to find the one element that appears exactly one time. + +Example 1 +Input: @ints = (3, 3, 1) +Output: 1 +Example 2 +Input: @ints = (3, 2, 4, 2, 4) +Output: 3 +Example 3 +Input: @ints = (1) +Output: 1 +Example 4 +Input: @ints = (4, 3, 1, 1, 1, 4) +Output: 3 +=cut +use strict; +use Data::Dumper; + + +my @inputs = ([3, 3, 1],[3, 2, 4, 2, 4],[1],[4, 3, 1, 1, 1, 4]); + +foreach(@inputs){ + my $arr = $_; + my @A = @$arr; + my $result = findUnique(\@A); + print $result."\n"; +} + +sub findUnique { + my $array = shift; + my @nums = @$array; + my %seen; + my %deleted; + foreach(@nums){ + + if(exists($seen{$_})){ + $seen{$_} += 1; + $deleted{$_} = 1; + delete $seen{$_}; + }else{ + if(!exists($deleted{$_})){ + $seen{$_} = 1; + } + } + } + + my @values = keys %seen; + + return $values[0] if (@values); + return -1; + +} \ No newline at end of file diff --git a/challenge-283/santiago-leyva/perl/ch-2.pl b/challenge-283/santiago-leyva/perl/ch-2.pl new file mode 100644 index 0000000000..30b7ab6879 --- /dev/null +++ b/challenge-283/santiago-leyva/perl/ch-2.pl @@ -0,0 +1,59 @@ +=begin +You are given an array of positive integers, @ints. + +Write a script to return true if for every index i in the range 0 <= i < size of array, the digit i occurs exactly the $ints[$i] times in the given array otherwise return false. + +Example 1 +Input: @ints = (1, 2, 1, 0) +Ouput: true + +$ints[0] = 1, the digit 0 occurs exactly 1 time. +$ints[1] = 2, the digit 1 occurs exactly 2 times. +$ints[2] = 1, the digit 2 occurs exactly 1 time. +$ints[3] = 0, the digit 3 occurs 0 time. +Example 2 +Input: @ints = (0, 3, 0) +Ouput: false + +$ints[0] = 0, the digit 0 occurs 2 times rather than 0 time. +$ints[1] = 3, the digit 1 occurs 0 time rather than 3 times. +$ints[2] = 0, the digit 2 occurs exactly 0 time. +=cut +use strict; +use Data::Dumper; + + +my @inputs = ([1, 2, 1, 0],[0, 3, 0]); + +foreach(@inputs){ + my $arr = $_; + my @A = @$arr; + my $result = checkIndex(\@A); + print $result."\n"; +} + +sub checkIndex { + my $array = shift; + my @nums = @$array; + + my %seen; + my %deleted; + foreach(@nums){ + + if(exists($seen{$_})){ + $seen{$_} += 1; + }else{ + $seen{$_} = 1; + } + } + + my $i = 0; + foreach(@nums){ + if(!exists($seen{$i}) and $seen{$i} != $_){ + return 'false'; + } + $i++; + } + + return 'true'; +} \ No newline at end of file diff --git a/challenge-284/santiago-leyva/perl/ch-01.pl b/challenge-284/santiago-leyva/perl/ch-01.pl deleted file mode 100644 index 27060bf1a2..0000000000 --- a/challenge-284/santiago-leyva/perl/ch-01.pl +++ /dev/null @@ -1,56 +0,0 @@ -=begin -You are given an array of integers, @ints. - -Write a script to find the lucky integer if found otherwise return -1. If there are more than one then return the largest. - -A lucky integer is an integer that has a frequency in the array equal to its value. - -Example 1 -Input: @ints = (2, 2, 3, 4) -Output: 2 -Example 2 -Input: @ints = (1, 2, 2, 3, 3, 3) -Output: 3 -Example 3 -Input: @ints = (1, 1, 1, 3) -Output: -1 -=cut - -use strict; -use Data::Dumper; - - -my @inputs = ([2, 2, 3, 4],[1, 2, 2, 3, 3, 3],[1, 1, 1, 3]); - -foreach(@inputs){ - my $arr = $_; - my @A = @$arr; - my $result = luckyNumber(\@A); - print $result."\n"; -} - -sub luckyNumber { - my $array = shift; - my @nums = @$array; - - my %set; - - foreach(@nums){ - if(exists($set{$_})){ - $set{$_} += 1; - }else{ - $set{$_} = 1; - } - } - - my @largest; - foreach(sort {$a <=> $b} keys %set){ - if($set{$_} == $_){ - push @largest,$_; - } - } - - return $largest[-1] if (@largest); - return -1; - -} \ No newline at end of file diff --git a/challenge-284/santiago-leyva/perl/ch-02.pl b/challenge-284/santiago-leyva/perl/ch-02.pl deleted file mode 100644 index c2c454f4de..0000000000 --- a/challenge-284/santiago-leyva/perl/ch-02.pl +++ /dev/null @@ -1,86 +0,0 @@ -=begin -You are given two list of integers, @list1 and @list2. The elements in the @list2 are distinct and also in the @list1. - -Write a script to sort the elements in the @list1 such that the relative order of items in @list1 is same as in the @list2. Elements that is missing in @list2 should be placed at the end of @list1 in ascending order. - -Example 1 -Input: @list1 = (2, 3, 9, 3, 1, 4, 6, 7, 2, 8, 5) - @list2 = (2, 1, 4, 3, 5, 6) -Ouput: (2, 2, 1, 4, 3, 3, 5, 6, 7, 8, 9) -Example 2 -Input: @list1 = (3, 3, 4, 6, 2, 4, 2, 1, 3) - @list2 = (1, 3, 2) -Ouput: (1, 3, 3, 3, 2, 2, 4, 4, 6) -Example 3 -Input: @list1 = (3, 0, 5, 0, 2, 1, 4, 1, 1) - @list2 = (1, 0, 3, 2) -Ouput: (1, 1, 1, 0, 0, 3, 2, 4, 5) -=cut - -use strict; -use Data::Dumper; - - -my @A = (2, 3, 9, 3, 1, 4, 6, 7, 2, 8, 5); -my @B = (2, 1, 4, 3, 5, 6); - -my @result = customSort(\@A,\@B); -print join(" ",@result)."\n"; - -my @A = (3, 3, 4, 6, 2, 4, 2, 1, 3); -my @B = (1, 3, 2); -my @result = customSort(\@A,\@B); -print join(" ",@result)."\n"; - -my @A = (3, 0, 5, 0, 2, 1, 4, 1, 1); -my @B = (1, 0, 3, 2); -my @result = customSort(\@A,\@B); -print join(" ",@result)."\n"; - -sub customSort { - my ($arr1,$arr2) = @_; - - my @list1 = @$arr1; - my @list2 = @$arr2; - - my %set1 = createSet(\@list1); - my @sorted; - foreach(@list2){ - if(exists($set1{$_})){ - push @sorted,$_; - if(($set1{$_}) > 1){ - for(my $i=1;$i<(scalar($set1{$_}));$i++){ - push @sorted,$_; - } - } - delete $set1{$_}; - } - } - - foreach(sort {$a<=>$b} keys %set1){ - push @sorted,$_; - if(($set1{$_}) > 1){ - for(my $i=1;$i<(scalar($set1{$_}));$i++){ - push @sorted,$_; - } - } - } - #print join(" ",@sorted)."\n"; - return @sorted; - -} - -sub createSet { - my $input = shift; - my @A = @$input; - my %_set; - foreach(@A){ - if(exists($_set{$_})){ - $_set{$_} += 1; - }else{ - $_set{$_} = 1; - } - } - - return %_set; -} diff --git a/challenge-284/santiago-leyva/perl/ch-1.pl b/challenge-284/santiago-leyva/perl/ch-1.pl new file mode 100644 index 0000000000..27060bf1a2 --- /dev/null +++ b/challenge-284/santiago-leyva/perl/ch-1.pl @@ -0,0 +1,56 @@ +=begin +You are given an array of integers, @ints. + +Write a script to find the lucky integer if found otherwise return -1. If there are more than one then return the largest. + +A lucky integer is an integer that has a frequency in the array equal to its value. + +Example 1 +Input: @ints = (2, 2, 3, 4) +Output: 2 +Example 2 +Input: @ints = (1, 2, 2, 3, 3, 3) +Output: 3 +Example 3 +Input: @ints = (1, 1, 1, 3) +Output: -1 +=cut + +use strict; +use Data::Dumper; + + +my @inputs = ([2, 2, 3, 4],[1, 2, 2, 3, 3, 3],[1, 1, 1, 3]); + +foreach(@inputs){ + my $arr = $_; + my @A = @$arr; + my $result = luckyNumber(\@A); + print $result."\n"; +} + +sub luckyNumber { + my $array = shift; + my @nums = @$array; + + my %set; + + foreach(@nums){ + if(exists($set{$_})){ + $set{$_} += 1; + }else{ + $set{$_} = 1; + } + } + + my @largest; + foreach(sort {$a <=> $b} keys %set){ + if($set{$_} == $_){ + push @largest,$_; + } + } + + return $largest[-1] if (@largest); + return -1; + +} \ No newline at end of file diff --git a/challenge-284/santiago-leyva/perl/ch-2.pl b/challenge-284/santiago-leyva/perl/ch-2.pl new file mode 100644 index 0000000000..c2c454f4de --- /dev/null +++ b/challenge-284/santiago-leyva/perl/ch-2.pl @@ -0,0 +1,86 @@ +=begin +You are given two list of integers, @list1 and @list2. The elements in the @list2 are distinct and also in the @list1. + +Write a script to sort the elements in the @list1 such that the relative order of items in @list1 is same as in the @list2. Elements that is missing in @list2 should be placed at the end of @list1 in ascending order. + +Example 1 +Input: @list1 = (2, 3, 9, 3, 1, 4, 6, 7, 2, 8, 5) + @list2 = (2, 1, 4, 3, 5, 6) +Ouput: (2, 2, 1, 4, 3, 3, 5, 6, 7, 8, 9) +Example 2 +Input: @list1 = (3, 3, 4, 6, 2, 4, 2, 1, 3) + @list2 = (1, 3, 2) +Ouput: (1, 3, 3, 3, 2, 2, 4, 4, 6) +Example 3 +Input: @list1 = (3, 0, 5, 0, 2, 1, 4, 1, 1) + @list2 = (1, 0, 3, 2) +Ouput: (1, 1, 1, 0, 0, 3, 2, 4, 5) +=cut + +use strict; +use Data::Dumper; + + +my @A = (2, 3, 9, 3, 1, 4, 6, 7, 2, 8, 5); +my @B = (2, 1, 4, 3, 5, 6); + +my @result = customSort(\@A,\@B); +print join(" ",@result)."\n"; + +my @A = (3, 3, 4, 6, 2, 4, 2, 1, 3); +my @B = (1, 3, 2); +my @result = customSort(\@A,\@B); +print join(" ",@result)."\n"; + +my @A = (3, 0, 5, 0, 2, 1, 4, 1, 1); +my @B = (1, 0, 3, 2); +my @result = customSort(\@A,\@B); +print join(" ",@result)."\n"; + +sub customSort { + my ($arr1,$arr2) = @_; + + my @list1 = @$arr1; + my @list2 = @$arr2; + + my %set1 = createSet(\@list1); + my @sorted; + foreach(@list2){ + if(exists($set1{$_})){ + push @sorted,$_; + if(($set1{$_}) > 1){ + for(my $i=1;$i<(scalar($set1{$_}));$i++){ + push @sorted,$_; + } + } + delete $set1{$_}; + } + } + + foreach(sort {$a<=>$b} keys %set1){ + push @sorted,$_; + if(($set1{$_}) > 1){ + for(my $i=1;$i<(scalar($set1{$_}));$i++){ + push @sorted,$_; + } + } + } + #print join(" ",@sorted)."\n"; + return @sorted; + +} + +sub createSet { + my $input = shift; + my @A = @$input; + my %_set; + foreach(@A){ + if(exists($_set{$_})){ + $_set{$_} += 1; + }else{ + $_set{$_} = 1; + } + } + + return %_set; +} diff --git a/challenge-285/santiago-leyva/perl/ch-01.pl b/challenge-285/santiago-leyva/perl/ch-01.pl deleted file mode 100644 index 3b1b1ce918..0000000000 --- a/challenge-285/santiago-leyva/perl/ch-01.pl +++ /dev/null @@ -1,58 +0,0 @@ -=begin -You are given a list of routes, @routes. - -Write a script to find the destination with no further outgoing connection. - -Example 1 -Input: @routes = (["B","C"], ["D","B"], ["C","A"]) -Output: "A" - -"D" -> "B" -> "C" -> "A". -"B" -> "C" -> "A". -"C" -> "A". -"A". -Example 2 -Input: @routes = (["A","Z"]) -Output: "Z" -=cut - -use strict; -use Data::Dumper; - -my @input = ([["B","C"], ["D","B"], ["C","A"]],[["A","Z"]]); - -foreach(@input){ - my $arr = $_; - my @A = @$arr; - my $dead_end = findDeadEnd(\@A); - print $dead_end."\n"; -} - -sub findDeadEnd { - my $array = shift; - my @route = @$array; - my @origin; - my @destination; - my @deadend; - for(0..scalar @route-1){ - push @origin, $route[$_][0]; - } - for(0..scalar @route-1){ - push @destination, $route[$_][1]; - } - - foreach my $i (@destination){ - if( !(grep( /^$i$/, @origin)) ){ - push @deadend, $i; - } - - } - - if(scalar @deadend > 1){ - return "There are multiple routes with no outgoing connection"; - }elsif(scalar @deadend == 0){ - return "All routes have an outgoing connection"; - } - return $deadend[0]; - -} diff --git a/challenge-285/santiago-leyva/perl/ch-02.pl b/challenge-285/santiago-leyva/perl/ch-02.pl deleted file mode 100644 index 6ebc42be82..0000000000 --- a/challenge-285/santiago-leyva/perl/ch-02.pl +++ /dev/null @@ -1,66 +0,0 @@ -=begin -Compute the number of ways to make change for given amount in cents. By using the coins e.g. Penny, Nickel, Dime, Quarter and Half-dollar, in how many distinct ways can the total value equal to the given amount? Order of coin selection does not matter. - -A penny (P) is equal to 1 cent. -A nickel (N) is equal to 5 cents. -A dime (D) is equal to 10 cents. -A quarter (Q) is equal to 25 cents. -A half-dollar (HD) is equal to 50 cents. -Example 1 -Input: $amount = 9 -Ouput: 2 - -1: 9P -2: N + 4P -Example 2 -Input: $amount = 15 -Ouput: 6 - -1: D + 5P -2: D + N -3: 3N -4: 2N + 5P -5: N + 10P -6: 15P -Example 3 -Input: $amount = 100 -Ouput: 292 -=cut - -use strict; -use Data::Dumper; - -use Test::More tests => 3; - -is(makeChange(9),2,'Test 1'); -is(makeChange(15),6,'Test 2'); -is(makeChange(100),292,'Test 3'); - - -my @amount = (9,15,100); - -foreach(@amount){ - my $_last_coin; - my $combination = makeChange($_,$_last_coin); - print "Number of Combinations for $_ is: $combination\n"; -} - -sub makeChange { - my ($reamaining,$last_coin) = @_; - my $combinations = 0; - my @denomination = (1,5,10,25,50); - #print "$reamaining,$last_coin\n"; - foreach my $coin (@denomination){ - if($last_coin and $last_coin < $coin){ - #print "$last_coin < $coin next\n"; - last; - }elsif($coin == $reamaining){ - $combinations += 1; - }elsif($coin < $reamaining){ - $combinations += makeChange($reamaining-$coin,$coin); - } - } - - return $combinations; - -} \ No newline at end of file diff --git a/challenge-285/santiago-leyva/perl/ch-1.pl b/challenge-285/santiago-leyva/perl/ch-1.pl new file mode 100644 index 0000000000..3b1b1ce918 --- /dev/null +++ b/challenge-285/santiago-leyva/perl/ch-1.pl @@ -0,0 +1,58 @@ +=begin +You are given a list of routes, @routes. + +Write a script to find the destination with no further outgoing connection. + +Example 1 +Input: @routes = (["B","C"], ["D","B"], ["C","A"]) +Output: "A" + +"D" -> "B" -> "C" -> "A". +"B" -> "C" -> "A". +"C" -> "A". +"A". +Example 2 +Input: @routes = (["A","Z"]) +Output: "Z" +=cut + +use strict; +use Data::Dumper; + +my @input = ([["B","C"], ["D","B"], ["C","A"]],[["A","Z"]]); + +foreach(@input){ + my $arr = $_; + my @A = @$arr; + my $dead_end = findDeadEnd(\@A); + print $dead_end."\n"; +} + +sub findDeadEnd { + my $array = shift; + my @route = @$array; + my @origin; + my @destination; + my @deadend; + for(0..scalar @route-1){ + push @origin, $route[$_][0]; + } + for(0..scalar @route-1){ + push @destination, $route[$_][1]; + } + + foreach my $i (@destination){ + if( !(grep( /^$i$/, @origin)) ){ + push @deadend, $i; + } + + } + + if(scalar @deadend > 1){ + return "There are multiple routes with no outgoing connection"; + }elsif(scalar @deadend == 0){ + return "All routes have an outgoing connection"; + } + return $deadend[0]; + +} diff --git a/challenge-285/santiago-leyva/perl/ch-2.pl b/challenge-285/santiago-leyva/perl/ch-2.pl new file mode 100644 index 0000000000..6ebc42be82 --- /dev/null +++ b/challenge-285/santiago-leyva/perl/ch-2.pl @@ -0,0 +1,66 @@ +=begin +Compute the number of ways to make change for given amount in cents. By using the coins e.g. Penny, Nickel, Dime, Quarter and Half-dollar, in how many distinct ways can the total value equal to the given amount? Order of coin selection does not matter. + +A penny (P) is equal to 1 cent. +A nickel (N) is equal to 5 cents. +A dime (D) is equal to 10 cents. +A quarter (Q) is equal to 25 cents. +A half-dollar (HD) is equal to 50 cents. +Example 1 +Input: $amount = 9 +Ouput: 2 + +1: 9P +2: N + 4P +Example 2 +Input: $amount = 15 +Ouput: 6 + +1: D + 5P +2: D + N +3: 3N +4: 2N + 5P +5: N + 10P +6: 15P +Example 3 +Input: $amount = 100 +Ouput: 292 +=cut + +use strict; +use Data::Dumper; + +use Test::More tests => 3; + +is(makeChange(9),2,'Test 1'); +is(makeChange(15),6,'Test 2'); +is(makeChange(100),292,'Test 3'); + + +my @amount = (9,15,100); + +foreach(@amount){ + my $_last_coin; + my $combination = makeChange($_,$_last_coin); + print "Number of Combinations for $_ is: $combination\n"; +} + +sub makeChange { + my ($reamaining,$last_coin) = @_; + my $combinations = 0; + my @denomination = (1,5,10,25,50); + #print "$reamaining,$last_coin\n"; + foreach my $coin (@denomination){ + if($last_coin and $last_coin < $coin){ + #print "$last_coin < $coin next\n"; + last; + }elsif($coin == $reamaining){ + $combinations += 1; + }elsif($coin < $reamaining){ + $combinations += makeChange($reamaining-$coin,$coin); + } + } + + return $combinations; + +} \ No newline at end of file diff --git a/stats/pwc-challenge-199.json b/stats/pwc-challenge-199.json index ffb672f477..d05735b316 100644 --- a/stats/pwc-challenge-199.json +++ b/stats/pwc-challenge-199.json @@ -1,8 +1,9 @@ { - "yAxis" : { - "title" : { - "text" : "Total Solutions" - } + "legend" : { + "enabled" : 0 + }, + "chart" : { + "type" : "column" }, "drilldown" : { "series" : [ @@ -21,6 +22,8 @@ "id" : "Adam Russell" }, { + "id" : "Ali Moradi", + "name" : "Ali Moradi", "data" : [ [ "Perl", @@ -30,13 +33,11 @@ "Raku", 2 ] - ], - "id" : "Ali Moradi", - "name" : "Ali Moradi" + ] }, { - "name" : "Arne Sommer", "id" : "Arne Sommer", + "name" : "Arne Sommer", "data" : [ [ "Raku", @@ -49,16 +50,18 @@ ] }, { - "name" : "Arpad Toth", - "id" : "Arpad Toth", "data" : [ [ "Perl", 2 ] - ] + ], + "name" : "Arpad Toth", + "id" : "Arpad Toth" }, { + "id" : "Athanasius", + "name" : "Athanasius", "data" : [ [ "Perl", @@ -68,43 +71,39 @@ "Raku", 2 ] - ], - "name" : "Athanasius", - "id" : "Athanasius" + ] }, { + "id" : "Bob Lied", + "name" : "Bob Lied", "data" : [ [ "Perl", 2 ] - ], - "name" : "Bob Lied", - "id" : "Bob Lied" + ] }, { + "id" : "Carlos Oliveira", + "name" : "Carlos Oliveira", "data" : [ [ "Raku", 2 ] - ], - "id" : "Carlos Oliveira", - "name" : "Carlos Oliveira" + ] }, { "id" : "Cheok-Yin Fung", - "name" : "Cheok-Yin Fung", "data" : [ [ "Perl", 2 ] - ] + ], + "name" : "Cheok-Yin Fung" }, { - "name" : "Colin Crain", - "id" : "Colin Crain", "data" : [ [ "Perl", @@ -114,10 +113,11 @@ "Blog", 1 ] - ] + ], + "name" : "Colin Crain", + "id" : "Colin Crain" }, { - "id" : "Dave Jacoby", "name" : "Dave Jacoby", "data" : [ [ @@ -128,9 +128,11 @@ "Blog", 1 ] - ] + ], + "id" : "Dave Jacoby" }, { + "name" : "David Ferrone", "data" : [ [ "Perl", @@ -141,12 +143,11 @@ 2 ] ], - "id" : "David Ferrone", - "name" : "David Ferrone" + "id" : "David Ferrone" }, { - "name" : "Duncan C. White", "id" : "Duncan C. White", + "name" : "Duncan C. White", "data" : [ [ "Perl", @@ -155,14 +156,14 @@ ] }, { - "name" : "E. Choroba", - "id" : "E. Choroba", "data" : [ [ "Perl", 2 ] - ] + ], + "name" : "E. Choroba", + "id" : "E. Choroba" }, { "data" : [ @@ -171,10 +172,12 @@ 2 ] ], - "id" : "Feng Chang", - "name" : "Feng Chang" + "name" : "Feng Chang", + "id" : "Feng Chang" }, { + "id" : "Flavio Poletti", + "name" : "Flavio Poletti", "data" : [ [ "Perl", @@ -188,9 +191,7 @@ "Blog", 2 ] - ], - "name" : "Flavio Poletti", - "id" : "Flavio Poletti" + ] }, { "data" : [ @@ -207,12 +208,11 @@ 1 ] ], - "id" : "Jaldhar H. Vyas", - "name" : "Jaldhar H. Vyas" + "name" : "Jaldhar H. Vyas", + "id" : "Jaldhar H. Vyas" }, { "id" : "James Smith", - "name" : "James Smith", "data" : [ [ "Perl", @@ -222,7 +222,8 @@ "Blog", 1 ] - ] + ], + "name" : "James Smith" }, { "id" : "Jan Krnavek", @@ -235,16 +236,18 @@ ] }, { - "name" : "Jorg Sommrey", - "id" : "Jorg Sommrey", "data" : [ [ "Perl", 2 ] - ] + ], + "name" : "Jorg Sommrey", + "id" : "Jorg Sommrey" }, { + "id" : "Laurent Rosenfeld", + "name" : "Laurent Rosenfeld", "data" : [ [ "Perl", @@ -258,12 +261,9 @@ "Blog", 1 ] - ], - "id" : "Laurent Rosenfeld", - "name" : "Laurent Rosenfeld" + ] }, { - "name" : "Lubos Kolouch", "id" : "Lubos Kolouch", "data" : [ [ @@ -274,11 +274,11 @@ "Blog", 1 ] - ] + ], + "name" : "Lubos Kolouch" }, { "name" : "Luca Ferrari", - "id" : "Luca Ferrari", "data" : [ [ "Raku", @@ -288,11 +288,12 @@ "Blog", 6 ] - ] + ], + "id" : "Luca Ferrari" }, { - "name" : "Mariano Spadaccini", "id" : "Mariano Spadaccini", + "name" : "Mariano Spadaccini", "data" : [ [ "Perl", @@ -311,24 +312,24 @@ ] }, { - "id" : "Niels van Dijke", - "name" : "Niels van Dijke", "data" : [ [ "Perl", 2 ] - ] + ], + "name" : "Niels van Dijke", + "id" : "Niels van Dijke" }, { "id" : "Paulo Custodio", - "name" : "Paulo Custodio", "data" : [ [ "Perl", 2 ] - ] + ], + "name" : "Paulo Custodio" }, { "data" : [ @@ -341,30 +342,41 @@ 1 ] ], - "id" : "Peter Campbell Smith", - "name" : "Peter Campbell Smith" + "name" : "Peter Campbell Smith", + "id" : "Peter Campbell Smith" + }, + { + "data" : [ + [ + "Perl", + 2 + ] + ], + "name" : "Peter Meszaros", + "id" : "Peter Meszaros" }, { - "id" : "Pip Stuart", "name" : "Pip Stuart", "data" : [ [ "Perl", 2 ] - ] + ], + "id" : "Pip Stuart" }, { + "name" : "Rawley Fowler", "data" : [ [ "Raku", 2 ] ], - "name" : "Rawley Fowler", "id" : "Rawley Fowler" }, { + "id" : "Robbie Hatley", "data" : [ [ "Perl", @@ -375,10 +387,10 @@ 1 ] ], - "name" : "Robbie Hatley", - "id" : "Robbie Hatley" + "name" : "Robbie Hatley" }, { + "id" : "Robert DiCicco", "data" : [ [ "Perl", @@ -389,12 +401,11 @@ 2 ] ], - "id" : "Robert DiCicco", "name" : "Robert DiCicco" }, { - "name" : "Robert Ransbottom", "id" : "Robert Ransbottom", + "name" : "Robert Ransbottom", "data" : [ [ "Raku", @@ -404,7 +415,6 @@ }, { "id" : "Roger Bell_West", - "name" : "Roger Bell_West", "data" : [ [ "Perl", @@ -418,10 +428,10 @@ "Blog", 1 ] - ] + ], + "name" : "Roger Bell_West" }, { - "id" : "Simon Green", "name" : "Simon Green", "data" : [ [ @@ -432,11 +442,12 @@ "Blog", 1 ] - ] + ], + "id" : "Simon Green" }, { - "name" : "Solathian", "id" : "Solathian", + "name" : "Solathian", "data" : [ [ "Perl", @@ -463,6 +474,7 @@ ] }, { + "name" : "Thomas Kohler", "data" : [ [ "Perl", @@ -473,11 +485,9 @@ 2 ] ], - "id" : "Thomas Kohler", - "name" : "Thomas Kohler" + "id" : "Thomas Kohler" }, { - "id" : "W. Luis Mochan", "name" : "W. Luis Mochan", "data" : [ [ @@ -488,22 +498,25 @@ "Blog", 1 ] - ] + ], + "id" : "W. Luis Mochan" } ] }, - "legend" : { - "enabled" : 0 + "tooltip" : { + "followPointer" : 1, + "headerFormat" : "{series.name}
", + "pointFormat" : "{point.name}: {point.y:f}
" }, "series" : [ { - "name" : "The Weekly Challenge - 199", "colorByPoint" : 1, + "name" : "The Weekly Challenge - 199", "data" : [ { - "drilldown" : "Adam Russell", + "name" : "Adam Russell", "y" : 4, - "name" : "Adam Russell" + "drilldown" : "Adam Russell" }, { "name" : "Ali Moradi", @@ -516,29 +529,29 @@ "y" : 3 }, { - "name" : "Arpad Toth", "drilldown" : "Arpad Toth", - "y" : 2 + "y" : 2, + "name" : "Arpad Toth" }, { - "name" : "Athanasius", + "y" : 4, "drilldown" : "Athanasius", - "y" : 4 + "name" : "Athanasius" }, { - "name" : "Bob Lied", + "drilldown" : "Bob Lied", "y" : 2, - "drilldown" : "Bob Lied" + "name" : "Bob Lied" }, { - "name" : "Carlos Oliveira", + "y" : 2, "drilldown" : "Carlos Oliveira", - "y" : 2 + "name" : "Carlos Oliveira" }, { - "y" : 2, + "name" : "Cheok-Yin Fung", "drilldown" : "Cheok-Yin Fung", - "name" : "Cheok-Yin Fung" + "y" : 2 }, { "drilldown" : "Colin Crain", @@ -546,34 +559,34 @@ "name" : "Colin Crain" }, { + "name" : "Dave Jacoby", "y" : 3, - "drilldown" : "Dave Jacoby", - "name" : "Dave Jacoby" + "drilldown" : "Dave Jacoby" }, { + "name" : "David Ferrone", "y" : 4, - "drilldown" : "David Ferrone", - "name" : "David Ferrone" + "drilldown" : "David Ferrone" }, { - "name" : "Duncan C. White", + "y" : 2, "drilldown" : "Duncan C. White", - "y" : 2 + "name" : "Duncan C. White" }, { - "y" : 2, "drilldown" : "E. Choroba", + "y" : 2, "name" : "E. Choroba" }, { - "name" : "Feng Chang", "drilldown" : "Feng Chang", - "y" : 2 + "y" : 2, + "name" : "Feng Chang" }, { - "y" : 6, + "name" : "Flavio Poletti", "drilldown" : "Flavio Poletti", - "name" : "Flavio Poletti" + "y" : 6 }, { "y" : 5, @@ -581,34 +594,34 @@ "name" : "Jaldhar H. Vyas" }, { - "name" : "James Smith", + "drilldown" : "James Smith", "y" : 3, - "drilldown" : "James Smith" + "name" : "James Smith" }, { + "name" : "Jan Krnavek", "y" : 2, - "drilldown" : "Jan Krnavek", - "name" : "Jan Krnavek" + "drilldown" : "Jan Krnavek" }, { - "y" : 2, + "name" : "Jorg Sommrey", "drilldown" : "Jorg Sommrey", - "name" : "Jorg Sommrey" + "y" : 2 }, { + "name" : "Laurent Rosenfeld", "drilldown" : "Laurent Rosenfeld", - "y" : 5, - "name" : "Laurent Rosenfeld" + "y" : 5 }, { - "name" : "Lubos Kolouch", + "drilldown" : "Lubos Kolouch", "y" : 3, - "drilldown" : "Lubos Kolouch" + "name" : "Lubos Kolouch" }, { - "name" : "Luca Ferrari", + "drilldown" : "Luca Ferrari", "y" : 8, - "drilldown" : "Luca Ferrari" + "name" : "Luca Ferrari" }, { "y" : 2, @@ -621,49 +634,54 @@ "name" : "Mark Anderson" }, { + "name" : "Niels van Dijke", "y" : 2, - "drilldown" : "Niels van Dijke", - "name" : "Niels van Dijke" + "drilldown" : "Niels van Dijke" }, { - "y" : 2, "drilldown" : "Paulo Custodio", + "y" : 2, "name" : "Paulo Custodio" }, { - "drilldown" : "Peter Campbell Smith", "y" : 3, + "drilldown" : "Peter Campbell Smith", "name" : "Peter Campbell Smith" }, + { + "name" : "Peter Meszaros", + "drilldown" : "Peter Meszaros", + "y" : 2 + }, { "name" : "Pip Stuart", - "y" : 2, - "drilldown" : "Pip Stuart" + "drilldown" : "Pip Stuart", + "y" : 2 }, { + "name" : "Rawley Fowler", "drilldown" : "Rawley Fowler", - "y" : 2, - "name" : "Rawley Fowler" + "y" : 2 }, { - "name" : "Robbie Hatley", "y" : 3, - "drilldown" : "Robbie Hatley" + "drilldown" : "Robbie Hatley", + "name" : "Robbie Hatley" }, { - "name" : "Robert DiCicco", "drilldown" : "Robert DiCicco", - "y" : 4 + "y" : 4, + "name" : "Robert DiCicco" }, { - "name" : "Robert Ransbottom", + "drilldown" : "Robert Ransbottom", "y" : 2, - "drilldown" : "Robert Ransbottom" + "name" : "Robert Ransbottom" }, { - "name" : "Roger Bell_West", + "y" : 5, "drilldown" : "Roger Bell_West", - "y" : 5 + "name" : "Roger Bell_West" }, { "y" : 3, @@ -672,8 +690,8 @@ }, { "name" : "Solathian", - "y" : 2, - "drilldown" : "Solathian" + "drilldown" : "Solathian", + "y" : 2 }, { "name" : "Stephen G. Lynn", @@ -682,41 +700,38 @@ }, { "name" : "Thomas Kohler", - "drilldown" : "Thomas Kohler", - "y" : 4 + "y" : 4, + "drilldown" : "Thomas Kohler" }, { - "name" : "W. Luis Mochan", "drilldown" : "W. Luis Mochan", - "y" : 3 + "y" : 3, + "name" : "W. Luis Mochan" } ] } ], - "title" : { - "text" : "The Weekly Challenge - 199" - }, - "xAxis" : { - "type" : "category" - }, "plotOptions" : { "series" : { + "borderWidth" : 0, "dataLabels" : { "enabled" : 1, "format" : "{point.y}" - }, - "borderWidth" : 0 + } } }, - "chart" : { - "type" : "column" + "xAxis" : { + "type" : "category" }, - "tooltip" : { - "headerFormat" : "{series.name}
", - "followPointer" : 1, - "pointFormat" : "{point.name}: {point.y:f}
" + "title" : { + "text" : "The Weekly Challenge - 199" + }, + "yAxis" : { + "title" : { + "text" : "Total Solutions" + } }, "subtitle" : { - "text" : "[Champions: 38] Last updated at 2024-07-29 17:29:09 GMT" + "text" : "[Champions: 39] Last updated at 2024-09-15 08:25:00 GMT" } } diff --git a/stats/pwc-challenge-283.json b/stats/pwc-challenge-283.json index 04ed7d0d9b..ebe284bd31 100644 --- a/stats/pwc-challenge-283.json +++ b/stats/pwc-challenge-283.json @@ -1,11 +1,18 @@ { - "title" : { - "text" : "The Weekly Challenge - 283" + "chart" : { + "type" : "column" + }, + "legend" : { + "enabled" : 0 + }, + "tooltip" : { + "pointFormat" : "{point.name}: {point.y:f}
", + "headerFormat" : "{series.name}
", + "followPointer" : 1 }, "drilldown" : { "series" : [ { - "name" : "Ali Moradi", "data" : [ [ "Perl", @@ -20,6 +27,7 @@ 1 ] ], + "name" : "Ali Moradi", "id" : "Ali Moradi" }, { @@ -34,13 +42,13 @@ }, { "name" : "Andrezgz", - "id" : "Andrezgz", "data" : [ [ "Perl", 2 ] - ] + ], + "id" : "Andrezgz" }, { "data" : [ @@ -53,11 +61,10 @@ 1 ] ], - "id" : "Arne Sommer", - "name" : "Arne Sommer" + "name" : "Arne Sommer", + "id" : "Arne Sommer" }, { - "name" : "Athanasius", "data" : [ [ "Perl", @@ -68,56 +75,57 @@ 2 ] ], + "name" : "Athanasius", "id" : "Athanasius" }, { - "name" : "BarrOff", "id" : "BarrOff", "data" : [ [ "Raku", 1 ] - ] + ], + "name" : "BarrOff" }, { - "id" : "Bob Lied", "data" : [ [ "Perl", 2 ] ], - "name" : "Bob Lied" + "name" : "Bob Lied", + "id" : "Bob Lied" }, { - "id" : "Cheok-Yin Fung", "data" : [ [ "Perl", 2 ] ], - "name" : "Cheok-Yin Fung" + "name" : "Cheok-Yin Fung", + "id" : "Cheok-Yin Fung" }, { - "name" : "Dave Jacoby", + "id" : "Dave Jacoby", "data" : [ [ "Perl", 2 ] ], - "id" : "Dave Jacoby" + "name" : "Dave Jacoby" }, { + "id" : "David Ferrone", "data" : [ [ "Perl", 2 ] ], - "id" : "David Ferrone", "name" : "David Ferrone" }, { @@ -127,12 +135,12 @@ 2 ] ], - "id" : "E. Choroba", - "name" : "E. Choroba" + "name" : "E. Choroba", + "id" : "E. Choroba" }, { - "name" : "Feng Chang", "id" : "Feng Chang", + "name" : "Feng Chang", "data" : [ [ "Raku", @@ -141,6 +149,7 @@ ] }, { + "id" : "Jaldhar H. Vyas", "name" : "Jaldhar H. Vyas", "data" : [ [ @@ -155,21 +164,20 @@ "Blog", 1 ] - ], - "id" : "Jaldhar H. Vyas" + ] }, { + "id" : "Jan Krnavek", "data" : [ [ "Raku", 2 ] ], - "id" : "Jan Krnavek", "name" : "Jan Krnavek" }, { - "id" : "Jorg Sommrey", + "name" : "Jorg Sommrey", "data" : [ [ "Perl", @@ -180,20 +188,19 @@ 1 ] ], - "name" : "Jorg Sommrey" + "id" : "Jorg Sommrey" }, { - "name" : "Kjetil Skotheim", "data" : [ [ "Perl", 2 ] ], + "name" : "Kjetil Skotheim", "id" : "Kjetil Skotheim" }, { - "id" : "Laurent Rosenfeld", "data" : [ [ "Perl", @@ -208,40 +215,40 @@ 2 ] ], - "name" : "Laurent Rosenfeld" + "name" : "Laurent Rosenfeld", + "id" : "Laurent Rosenfeld" }, { - "id" : "Mariano Ortega", "data" : [ [ "Perl", 2 ] ], - "name" : "Mariano Ortega" + "name" : "Mariano Ortega", + "id" : "Mariano Ortega" }, { + "id" : "Mark Anderson", + "name" : "Mark Anderson", "data" : [ [ "Raku", 2 ] - ], - "id" : "Mark Anderson", - "name" : "Mark Anderson" + ] }, { + "id" : "Matthew Neleigh", "data" : [ [ "Perl", 2 ] ], - "id" : "Matthew Neleigh", "name" : "Matthew Neleigh" }, { - "name" : "Matthias Muth", "id" : "Matthias Muth", "data" : [ [ @@ -252,11 +259,12 @@ "Blog", 1 ] - ] + ], + "name" : "Matthias Muth" }, { - "name" : "Nelo Tovar", "id" : "Nelo Tovar", + "name" : "Nelo Tovar", "data" : [ [ "Perl", @@ -265,17 +273,18 @@ ] }, { - "name" : "Niels van Dijke", + "id" : "Niels van Dijke", "data" : [ [ "Perl", 2 ] ], - "id" : "Niels van Dijke" + "name" : "Niels van Dijke" }, { "id" : "Packy Anderson", + "name" : "Packy Anderson", "data" : [ [ "Perl", @@ -289,18 +298,17 @@ "Blog", 1 ] - ], - "name" : "Packy Anderson" + ] }, { "name" : "Paulo Custodio", - "id" : "Paulo Custodio", "data" : [ [ "Perl", 2 ] - ] + ], + "id" : "Paulo Custodio" }, { "name" : "Peter Campbell Smith", @@ -317,17 +325,16 @@ "id" : "Peter Campbell Smith" }, { - "id" : "Peter Meszaros", + "name" : "Peter Meszaros", "data" : [ [ "Perl", 2 ] ], - "name" : "Peter Meszaros" + "id" : "Peter Meszaros" }, { - "id" : "Reinier Maliepaard", "data" : [ [ "Perl", @@ -338,7 +345,8 @@ 1 ] ], - "name" : "Reinier Maliepaard" + "name" : "Reinier Maliepaard", + "id" : "Reinier Maliepaard" }, { "name" : "Robbie Hatley", @@ -355,18 +363,17 @@ "id" : "Robbie Hatley" }, { - "name" : "Robert Ransbottom", + "id" : "Robert Ransbottom", "data" : [ [ "Raku", 2 ] ], - "id" : "Robert Ransbottom" + "name" : "Robert Ransbottom" }, { "name" : "Roger Bell_West", - "id" : "Roger Bell_West", "data" : [ [ "Perl", @@ -380,10 +387,20 @@ "Blog", 1 ] - ] + ], + "id" : "Roger Bell_West" + }, + { + "name" : "Santiago Leyva", + "data" : [ + [ + "Perl", + 2 + ] + ], + "id" : "Santiago Leyva" }, { - "id" : "Simon Green", "data" : [ [ "Perl", @@ -394,10 +411,10 @@ 1 ] ], - "name" : "Simon Green" + "name" : "Simon Green", + "id" : "Simon Green" }, { - "name" : "Thomas Kohler", "id" : "Thomas Kohler", "data" : [ [ @@ -408,10 +425,10 @@ "Blog", 2 ] - ] + ], + "name" : "Thomas Kohler" }, { - "name" : "Ulrich Rieke", "id" : "Ulrich Rieke", "data" : [ [ @@ -422,10 +439,12 @@ "Raku", 2 ] - ] + ], + "name" : "Ulrich Rieke" }, { "id" : "W. Luis Mochan", + "name" : "W. Luis Mochan", "data" : [ [ "Perl", @@ -435,12 +454,11 @@ "Blog", 1 ] - ], - "name" : "W. Luis Mochan" + ] }, { - "name" : "Wanderdoc", "id" : "Wanderdoc", + "name" : "Wanderdoc", "data" : [ [ "Perl", @@ -450,27 +468,18 @@ } ] }, - "legend" : { - "enabled" : 0 - }, - "chart" : { - "type" : "column" + "xAxis" : { + "type" : "category" }, "plotOptions" : { "series" : { - "borderWidth" : 0, "dataLabels" : { "format" : "{point.y}", "enabled" : 1 - } + }, + "borderWidth" : 0 } }, - "xAxis" : { - "type" : "category" - }, - "subtitle" : { - "text" : "[Champions: 36] Last updated at 2024-08-31 21:47:49 GMT" - }, "series" : [ { "colorByPoint" : 1, @@ -483,33 +492,33 @@ }, { "drilldown" : "Andrew Schneider", - "name" : "Andrew Schneider", - "y" : 2 + "y" : 2, + "name" : "Andrew Schneider" }, { + "name" : "Andrezgz", "y" : 2, - "drilldown" : "Andrezgz", - "name" : "Andrezgz" + "drilldown" : "Andrezgz" }, { - "y" : 3, "name" : "Arne Sommer", - "drilldown" : "Arne Sommer" + "drilldown" : "Arne Sommer", + "y" : 3 }, { "drilldown" : "Athanasius", - "name" : "Athanasius", - "y" : 4 + "y" : 4, + "name" : "Athanasius" }, { "y" : 1, - "name" : "BarrOff", - "drilldown" : "BarrOff" + "drilldown" : "BarrOff", + "name" : "BarrOff" }, { - "name" : "Bob Lied", "drilldown" : "Bob Lied", - "y" : 2 + "y" : 2, + "name" : "Bob Lied" }, { "y" : 2, @@ -517,39 +526,39 @@ "name" : "Cheok-Yin Fung" }, { + "y" : 2, "drilldown" : "Dave Jacoby", - "name" : "Dave Jacoby", - "y" : 2 + "name" : "Dave Jacoby" }, { + "drilldown" : "David Ferrone", "y" : 2, - "name" : "David Ferrone", - "drilldown" : "David Ferrone" + "name" : "David Ferrone" }, { - "y" : 2, + "name" : "E. Choroba", "drilldown" : "E. Choroba", - "name" : "E. Choroba" + "y" : 2 }, { "y" : 2, - "name" : "Feng Chang", - "drilldown" : "Feng Chang" + "drilldown" : "Feng Chang", + "name" : "Feng Chang" }, { "y" : 5, - "name" : "Jaldhar H. Vyas", - "drilldown" : "Jaldhar H. Vyas" + "drilldown" : "Jaldhar H. Vyas", + "name" : "Jaldhar H. Vyas" }, { + "name" : "Jan Krnavek", "y" : 2, - "drilldown" : "Jan Krnavek", - "name" : "Jan Krnavek" + "drilldown" : "Jan Krnavek" }, { + "name" : "Jorg Sommrey", "y" : 3, - "drilldown" : "Jorg Sommrey", - "name" : "Jorg Sommrey" + "drilldown" : "Jorg Sommrey" }, { "name" : "Kjetil Skotheim", @@ -557,23 +566,23 @@ "y" : 2 }, { - "y" : 6, + "name" : "Laurent Rosenfeld", "drilldown" : "Laurent Rosenfeld", - "name" : "Laurent Rosenfeld" + "y" : 6 }, { - "y" : 2, "name" : "Mariano Ortega", + "y" : 2, "drilldown" : "Mariano Ortega" }, { - "y" : 2, + "name" : "Mark Anderson", "drilldown" : "Mark Anderson", - "name" : "Mark Anderson" + "y" : 2 }, { - "y" : 2, "name" : "Matthew Neleigh", + "y" : 2, "drilldown" : "Matthew Neleigh" }, { @@ -583,12 +592,12 @@ }, { "drilldown" : "Nelo Tovar", - "name" : "Nelo Tovar", - "y" : 2 + "y" : 2, + "name" : "Nelo Tovar" }, { - "drilldown" : "Niels van Dijke", "name" : "Niels van Dijke", + "drilldown" : "Niels van Dijke", "y" : 2 }, { @@ -603,43 +612,48 @@ }, { "name" : "Peter Campbell Smith", - "drilldown" : "Peter Campbell Smith", - "y" : 3 + "y" : 3, + "drilldown" : "Peter Campbell Smith" }, { - "y" : 2, "drilldown" : "Peter Meszaros", + "y" : 2, "name" : "Peter Meszaros" }, { - "y" : 3, "name" : "Reinier Maliepaard", + "y" : 3, "drilldown" : "Reinier Maliepaard" }, { + "y" : 3, "drilldown" : "Robbie Hatley", - "name" : "Robbie Hatley", - "y" : 3 + "name" : "Robbie Hatley" }, { + "name" : "Robert Ransbottom", "y" : 2, - "drilldown" : "Robert Ransbottom", - "name" : "Robert Ransbottom" + "drilldown" : "Robert Ransbottom" }, { - "y" : 5, + "name" : "Roger Bell_West", "drilldown" : "Roger Bell_West", - "name" : "Roger Bell_West" + "y" : 5 + }, + { + "name" : "Santiago Leyva", + "drilldown" : "Santiago Leyva", + "y" : 2 }, { - "drilldown" : "Simon Green", "name" : "Simon Green", - "y" : 3 + "y" : 3, + "drilldown" : "Simon Green" }, { - "y" : 4, + "name" : "Thomas Kohler", "drilldown" : "Thomas Kohler", - "name" : "Thomas Kohler" + "y" : 4 }, { "y" : 4, @@ -647,26 +661,27 @@ "name" : "Ulrich Rieke" }, { - "drilldown" : "W. Luis Mochan", "name" : "W. Luis Mochan", + "drilldown" : "W. Luis Mochan", "y" : 3 }, { - "name" : "Wanderdoc", "drilldown" : "Wanderdoc", - "y" : 2 + "y" : 2, + "name" : "Wanderdoc" } ] } ], + "subtitle" : { + "text" : "[Champions: 37] Last updated at 2024-09-15 08:25:00 GMT" + }, "yAxis" : { "title" : { "text" : "Total Solutions" } }, - "tooltip" : { - "pointFormat" : "{point.name}: {point.y:f}
", - "headerFormat" : "{series.name}
", - "followPointer" : 1 + "title" : { + "text" : "The Weekly Challenge - 283" } } diff --git a/stats/pwc-challenge-284.json b/stats/pwc-challenge-284.json index 37827b2083..4be4da4e5a 100644 --- a/stats/pwc-challenge-284.json +++ b/stats/pwc-challenge-284.json @@ -1,236 +1,15 @@ { - "xAxis" : { - "type" : "category" - }, "legend" : { "enabled" : 0 }, "chart" : { "type" : "column" }, - "plotOptions" : { - "series" : { - "borderWidth" : 0, - "dataLabels" : { - "enabled" : 1, - "format" : "{point.y}" - } - } - }, - "series" : [ - { - "name" : "The Weekly Challenge - 284", - "data" : [ - { - "y" : 3, - "drilldown" : "Ali Moradi", - "name" : "Ali Moradi" - }, - { - "y" : 2, - "drilldown" : "Andrew Schneider", - "name" : "Andrew Schneider" - }, - { - "name" : "Arne Sommer", - "drilldown" : "Arne Sommer", - "y" : 3 - }, - { - "drilldown" : "Athanasius", - "y" : 4, - "name" : "Athanasius" - }, - { - "drilldown" : "BarrOff", - "y" : 1, - "name" : "BarrOff" - }, - { - "y" : 2, - "drilldown" : "Bob Lied", - "name" : "Bob Lied" - }, - { - "y" : 2, - "drilldown" : "Cheok-Yin Fung", - "name" : "Cheok-Yin Fung" - }, - { - "name" : "Dave Jacoby", - "drilldown" : "Dave Jacoby", - "y" : 2 - }, - { - "name" : "David Ferrone", - "drilldown" : "David Ferrone", - "y" : 2 - }, - { - "name" : "E. Choroba", - "y" : 2, - "drilldown" : "E. Choroba" - }, - { - "y" : 2, - "drilldown" : "Feng Chang", - "name" : "Feng Chang" - }, - { - "drilldown" : "Jaldhar H. Vyas", - "y" : 5, - "name" : "Jaldhar H. Vyas" - }, - { - "y" : 2, - "drilldown" : "Jan Krnavek", - "name" : "Jan Krnavek" - }, - { - "name" : "Jorg Sommrey", - "drilldown" : "Jorg Sommrey", - "y" : 4 - }, - { - "y" : 2, - "drilldown" : "Kjetil Skotheim", - "name" : "Kjetil Skotheim" - }, - { - "name" : "Laurent Rosenfeld", - "y" : 6, - "drilldown" : "Laurent Rosenfeld" - }, - { - "y" : 2, - "drilldown" : "Mariano Ortega", - "name" : "Mariano Ortega" - }, - { - "name" : "Mariano Spadaccini", - "drilldown" : "Mariano Spadaccini", - "y" : 2 - }, - { - "name" : "Mark Anderson", - "drilldown" : "Mark Anderson", - "y" : 2 - }, - { - "y" : 2, - "drilldown" : "Matthew Neleigh", - "name" : "Matthew Neleigh" - }, - { - "drilldown" : "Matthias Muth", - "y" : 3, - "name" : "Matthias Muth" - }, - { - "y" : 2, - "drilldown" : "Nelo Tovar", - "name" : "Nelo Tovar" - }, - { - "name" : "Niels van Dijke", - "y" : 2, - "drilldown" : "Niels van Dijke" - }, - { - "name" : "Packy Anderson", - "drilldown" : "Packy Anderson", - "y" : 5 - }, - { - "y" : 2, - "drilldown" : "Paulo Custodio", - "name" : "Paulo Custodio" - }, - { - "y" : 3, - "drilldown" : "Peter Campbell Smith", - "name" : "Peter Campbell Smith" - }, - { - "name" : "Peter Meszaros", - "drilldown" : "Peter Meszaros", - "y" : 2 - }, - { - "name" : "Reinier Maliepaard", - "