From db4d9fe6bf77ff58c31ec3e9d2f71d8acf7d58d4 Mon Sep 17 00:00:00 2001 From: Mohammad S Anwar Date: Tue, 7 Nov 2023 15:11:45 +0000 Subject: - Added solutions by Eric Cheung. - Added solutions by Laurent Rosenfeld. - Added solutions by Mark Anderson. - Added solutions by Matthias Muth. - Added solutions by Athanasius. - Added solutions by Niels van Dijke. - Added solutions by Simon Proctor. - Added solutions by Packy Anderson. - Added solutions by David Ferrone. - Added solutions by W. Luis Mochan. - Added solutions by Thomas Kohler. - Added solutions by Paulo Custodio. - Added solutions by Matthew Neleigh. - Added solutions by Robbie Hatley. - Added solutions by PokGoPun. - Added solutions by Luca Ferrari. - Added solutions by Peter Campbell Smith. - Added solutions by E. Choroba. - Added solutions by Roger Bell_West. --- challenge-242/clifton-wood/raku/ch-1.raku | 10 + challenge-242/clifton-wood/raku/ch-2.raku | 4 + challenge-242/eric-cheung/python/ch-1.py | 20 + challenge-242/eric-cheung/python/ch-2.py | 11 + challenge-242/laurent-rosenfeld/blog.txt | 1 + challenge-242/laurent-rosenfeld/perl/ch-1.pl | 21 + challenge-242/laurent-rosenfeld/raku/ch-1.raku | 8 + challenge-242/perlboy1967/perl/ch-1.pl | 54 + challenge-242/perlboy1967/perl/ch-2.pl | 33 + challenge-242/perlboy1967/perl/ch1.pl | 54 - challenge-242/perlboy1967/perl/ch2.pl | 33 - challenge-242/ulrich-rieke/cpp/ch-1.cpp | 59 + challenge-242/ulrich-rieke/cpp/ch-2.cpp | 62 + challenge-242/ulrich-rieke/haskell/ch-1.hs | 21 + challenge-242/ulrich-rieke/haskell/ch-2.hs | 32 + challenge-242/ulrich-rieke/perl/ch-1.pl | 29 + challenge-242/ulrich-rieke/perl/ch-2.pl | 40 + challenge-242/ulrich-rieke/raku/ch-1.raku | 22 + challenge-242/ulrich-rieke/raku/ch-2.raku | 34 + challenge-242/ulrich-rieke/rust/ch-1.rs | 29 + challenge-242/ulrich-rieke/rust/ch-2.rs | 41 + stats/pwc-challenge-241.json | 695 ++ stats/pwc-current.json | 538 +- stats/pwc-language-breakdown-summary.json | 66 +- stats/pwc-language-breakdown.json | 9495 ++++++++++++------------ stats/pwc-leaders.json | 824 +- stats/pwc-summary-1-30.json | 98 +- stats/pwc-summary-121-150.json | 52 +- stats/pwc-summary-151-180.json | 56 +- stats/pwc-summary-181-210.json | 102 +- stats/pwc-summary-211-240.json | 120 +- stats/pwc-summary-241-270.json | 50 +- stats/pwc-summary-271-300.json | 118 +- stats/pwc-summary-31-60.json | 116 +- stats/pwc-summary-61-90.json | 56 +- stats/pwc-summary-91-120.json | 80 +- stats/pwc-summary.json | 1868 ++--- 37 files changed, 7885 insertions(+), 7067 deletions(-) create mode 100644 challenge-242/clifton-wood/raku/ch-1.raku create mode 100644 challenge-242/clifton-wood/raku/ch-2.raku create mode 100755 challenge-242/eric-cheung/python/ch-1.py create mode 100755 challenge-242/eric-cheung/python/ch-2.py create mode 100644 challenge-242/laurent-rosenfeld/blog.txt create mode 100644 challenge-242/laurent-rosenfeld/perl/ch-1.pl create mode 100644 challenge-242/laurent-rosenfeld/raku/ch-1.raku create mode 100755 challenge-242/perlboy1967/perl/ch-1.pl create mode 100755 challenge-242/perlboy1967/perl/ch-2.pl delete mode 100755 challenge-242/perlboy1967/perl/ch1.pl delete mode 100755 challenge-242/perlboy1967/perl/ch2.pl create mode 100755 challenge-242/ulrich-rieke/cpp/ch-1.cpp create mode 100755 challenge-242/ulrich-rieke/cpp/ch-2.cpp create mode 100755 challenge-242/ulrich-rieke/haskell/ch-1.hs create mode 100755 challenge-242/ulrich-rieke/haskell/ch-2.hs create mode 100755 challenge-242/ulrich-rieke/perl/ch-1.pl create mode 100755 challenge-242/ulrich-rieke/perl/ch-2.pl create mode 100755 challenge-242/ulrich-rieke/raku/ch-1.raku create mode 100755 challenge-242/ulrich-rieke/raku/ch-2.raku create mode 100755 challenge-242/ulrich-rieke/rust/ch-1.rs create mode 100755 challenge-242/ulrich-rieke/rust/ch-2.rs create mode 100644 stats/pwc-challenge-241.json diff --git a/challenge-242/clifton-wood/raku/ch-1.raku b/challenge-242/clifton-wood/raku/ch-1.raku new file mode 100644 index 0000000000..de234fc88c --- /dev/null +++ b/challenge-242/clifton-wood/raku/ch-1.raku @@ -0,0 +1,10 @@ +my %h; +my @a = ; +my @b = ; %h{ |@a, |@b } »=» 1; +my (@m-a, @m-b); +for %h.keys { + @m-a.push: $_ unless @a.first($_).defined; + @m-b.push: $_ unless @b.first($_).defined; +} +@m-a.gist.say; +@m-b.gist.say; diff --git a/challenge-242/clifton-wood/raku/ch-2.raku b/challenge-242/clifton-wood/raku/ch-2.raku new file mode 100644 index 0000000000..1831ded48e --- /dev/null +++ b/challenge-242/clifton-wood/raku/ch-2.raku @@ -0,0 +1,4 @@ +my @matrix = ([1, 1, 0], [1, 0, 1], [0, 0, 0]); +@matrix.map( *.reverse.map( *.not.Int ) ).gist.say + + diff --git a/challenge-242/eric-cheung/python/ch-1.py b/challenge-242/eric-cheung/python/ch-1.py new file mode 100755 index 0000000000..b3d79cc846 --- /dev/null +++ b/challenge-242/eric-cheung/python/ch-1.py @@ -0,0 +1,20 @@ + +## Example 1 +## arrNum_01 = [1, 2, 3] +## arrNum_02 = [2, 4, 6] + +## Example 2 +arrNum_01 = [1, 2, 3, 3] +arrNum_02 = [1, 1, 2, 2] + +arrOutput = [] + +arrOutput_01 = [nLoop for nLoop in list(set(arrNum_01)) if nLoop not in list(set(arrNum_02))] +if len(arrOutput_01) > 0: + arrOutput.append(arrOutput_01) + +arrOutput_02 = [nLoop for nLoop in list(set(arrNum_02)) if nLoop not in list(set(arrNum_01))] +if len(arrOutput_02) > 0: + arrOutput.append(arrOutput_02) + +print (arrOutput) diff --git a/challenge-242/eric-cheung/python/ch-2.py b/challenge-242/eric-cheung/python/ch-2.py new file mode 100755 index 0000000000..9d487ad23a --- /dev/null +++ b/challenge-242/eric-cheung/python/ch-2.py @@ -0,0 +1,11 @@ + +arrMatrix = [[1, 1, 0], [0, 1, 1], [0, 0, 1]] ## Example 0 +## arrMatrix = [[1, 1, 0], [1, 0, 1], [0, 0, 0]] ## Example 1 +## arrMatrix = [[1, 1, 0, 0], [1, 0, 0, 1], [0, 1, 1, 1], [1, 0, 1, 0]] ## Example 2 + +arrOutput = [] + +for arrLoop in arrMatrix: + arrOutput.append([1 - nLoop for nLoop in arrLoop[::-1]]) + +print (arrOutput) diff --git a/challenge-242/laurent-rosenfeld/blog.txt b/challenge-242/laurent-rosenfeld/blog.txt new file mode 100644 index 0000000000..1d58249df0 --- /dev/null +++ b/challenge-242/laurent-rosenfeld/blog.txt @@ -0,0 +1 @@ +https://blogs.perl.org/users/laurent_r/2023/11/perl-weekly-challenge-242-missing-members.html diff --git a/challenge-242/laurent-rosenfeld/perl/ch-1.pl b/challenge-242/laurent-rosenfeld/perl/ch-1.pl new file mode 100644 index 0000000000..7f07643be9 --- /dev/null +++ b/challenge-242/laurent-rosenfeld/perl/ch-1.pl @@ -0,0 +1,21 @@ +use strict; +use warnings; +use feature 'say'; + +sub diff { + my ($aref, $bref) = @_; + my %a = map {$_ => 1} @$aref; + my %b = map {$_ => 1} @$bref; + my $adif = [grep { not exists $b{$_} } keys %a]; + my $bdif = [grep { not exists $a{$_} } keys %b]; + return "(@$adif) (@$bdif)"; +} + +my @tests = ( [[<1 2 3>], [<2 4 6>]], + [[<1 2 3 3>], [<1 1 2 2>]] + ); +for my $test (@tests) { + printf "%-10s - %-10s => ", + "@{$test->[0]}", "@{$test->[1]}"; + say diff ($test->[0], $test->[1]); +} diff --git a/challenge-242/laurent-rosenfeld/raku/ch-1.raku b/challenge-242/laurent-rosenfeld/raku/ch-1.raku new file mode 100644 index 0000000000..ac7891c025 --- /dev/null +++ b/challenge-242/laurent-rosenfeld/raku/ch-1.raku @@ -0,0 +1,8 @@ +sub diff (@a, @b) { + return map {.keys}, @a (-) @b, @b (-) @a; +} + +for (<1 2 3>, < 2 4 6>), (<1 2 3 3>, <1 1 2 2>) -> @test { + printf "%-8s - %-8s => ", "@test[0]", "@test[1]"; + say diff @test[0], @test[1]; +} diff --git a/challenge-242/perlboy1967/perl/ch-1.pl b/challenge-242/perlboy1967/perl/ch-1.pl new file mode 100755 index 0000000000..5954386f3e --- /dev/null +++ b/challenge-242/perlboy1967/perl/ch-1.pl @@ -0,0 +1,54 @@ +#!/bin/perl + +=pod + +The Weekly Challenge - 242 +- https://theweeklychallenge.org/blog/perl-weekly-challenge-242 + +Author: Niels 'PerlBoy' van Dijke + +Task 1: Missing Members +Submitted by: Mohammad S Anwar + +You are given two arrays of integers. + +Write a script to find out the missing members in each other arrays. + +=cut + +use v5.32; +use common::sense; + +use Test2::V0; + +use List::MoreUtils qw(uniq); + +sub missingMembers { + my ($n,%n,$r) = ($#_ + 1); + + # Collect all numbers across input + # and store against their input index + for my $i (0 .. $n - 1) { + $r->[$i] = []; + for (uniq($_[$i]->@*)) { + push(@{$n{$_}},$i); + } + } + + # Find uniq numbers across input + # and create output + for my $i (sort { $a <=> $b } keys %n) { + if ($n{$i}->@* < $n) { + map { push($r->[$_]->@*,$i) } $n{$i}->@*; + } + } + return $r; +} + +is(missingMembers([1,2,3],[2,4,6]), + [[1,3],[4,6]]); +is(missingMembers([0,1,2,3],[1,2,3,4],[2,3,4,5]), + [[0,1],[1,4],[4,5]]); +is(missingMembers([1],[1]),[[],[]]); + +done_testing; diff --git a/challenge-242/perlboy1967/perl/ch-2.pl b/challenge-242/perlboy1967/perl/ch-2.pl new file mode 100755 index 0000000000..3c4db8904a --- /dev/null +++ b/challenge-242/perlboy1967/perl/ch-2.pl @@ -0,0 +1,33 @@ +#!/bin/perl + +=pod + +The Weekly Challenge - 242 +- https://theweeklychallenge.org/blog/perl-weekly-challenge-242 + +Author: Niels 'PerlBoy' van Dijke + +Task 2: Flip Matrix +Submitted by: Mohammad S Anwar + +You are given n x n binary matrix. + +Write a script to flip the given matrix. + +=cut + +use v5.32; +use common::sense; + +use Test2::V0; + +sub flipMatrix { + [ map { [map { ++$_ % 2 } reverse @$_] } @_ ]; +} + +is(flipMatrix([1,1,0],[0,1,1],[0,0,1]), + [[1,0,0],[0,0,1],[0,1,1]]); +is(flipMatrix([1,1,0,0],[1,0,0,1],[0,1,1,1],[1,0,1,0]), + [[1,1,0,0],[0,1,1,0],[0,0,0,1],[1,0,1,0]]); + +done_testing; diff --git a/challenge-242/perlboy1967/perl/ch1.pl b/challenge-242/perlboy1967/perl/ch1.pl deleted file mode 100755 index 5954386f3e..0000000000 --- a/challenge-242/perlboy1967/perl/ch1.pl +++ /dev/null @@ -1,54 +0,0 @@ -#!/bin/perl - -=pod - -The Weekly Challenge - 242 -- https://theweeklychallenge.org/blog/perl-weekly-challenge-242 - -Author: Niels 'PerlBoy' van Dijke - -Task 1: Missing Members -Submitted by: Mohammad S Anwar - -You are given two arrays of integers. - -Write a script to find out the missing members in each other arrays. - -=cut - -use v5.32; -use common::sense; - -use Test2::V0; - -use List::MoreUtils qw(uniq); - -sub missingMembers { - my ($n,%n,$r) = ($#_ + 1); - - # Collect all numbers across input - # and store against their input index - for my $i (0 .. $n - 1) { - $r->[$i] = []; - for (uniq($_[$i]->@*)) { - push(@{$n{$_}},$i); - } - } - - # Find uniq numbers across input - # and create output - for my $i (sort { $a <=> $b } keys %n) { - if ($n{$i}->@* < $n) { - map { push($r->[$_]->@*,$i) } $n{$i}->@*; - } - } - return $r; -} - -is(missingMembers([1,2,3],[2,4,6]), - [[1,3],[4,6]]); -is(missingMembers([0,1,2,3],[1,2,3,4],[2,3,4,5]), - [[0,1],[1,4],[4,5]]); -is(missingMembers([1],[1]),[[],[]]); - -done_testing; diff --git a/challenge-242/perlboy1967/perl/ch2.pl b/challenge-242/perlboy1967/perl/ch2.pl deleted file mode 100755 index 3c4db8904a..0000000000 --- a/challenge-242/perlboy1967/perl/ch2.pl +++ /dev/null @@ -1,33 +0,0 @@ -#!/bin/perl - -=pod - -The Weekly Challenge - 242 -- https://theweeklychallenge.org/blog/perl-weekly-challenge-242 - -Author: Niels 'PerlBoy' van Dijke - -Task 2: Flip Matrix -Submitted by: Mohammad S Anwar - -You are given n x n binary matrix. - -Write a script to flip the given matrix. - -=cut - -use v5.32; -use common::sense; - -use Test2::V0; - -sub flipMatrix { - [ map { [map { ++$_ % 2 } reverse @$_] } @_ ]; -} - -is(flipMatrix([1,1,0],[0,1,1],[0,0,1]), - [[1,0,0],[0,0,1],[0,1,1]]); -is(flipMatrix([1,1,0,0],[1,0,0,1],[0,1,1,1],[1,0,1,0]), - [[1,1,0,0],[0,1,1,0],[0,0,0,1],[1,0,1,0]]); - -done_testing; diff --git a/challenge-242/ulrich-rieke/cpp/ch-1.cpp b/challenge-242/ulrich-rieke/cpp/ch-1.cpp new file mode 100755 index 0000000000..807d9becd9 --- /dev/null +++ b/challenge-242/ulrich-rieke/cpp/ch-1.cpp @@ -0,0 +1,59 @@ +#include +#include +#include +#include +#include +#include + +std::vector split( const std::string & startline , + const std::string & sep ) { + std::vector separated ; + std::string::size_type start { 0 } ; + std::string::size_type pos ; + do { + pos = startline.find_first_of( sep , start ) ; + separated.push_back( startline.substr(start , pos - start )) ; + start = pos + 1 ; + } while ( pos != std::string::npos ) ; + return separated ; +} + +int main( ) { + std::cout << "Enter some integers, separated by blanks!\n" ; + std::string line ; + std::getline( std::cin , line ) ; + std::vector numberstrings { split( line , " " ) } ; + std::vector firstNums , secondNums ; + for ( auto s : numberstrings ) + firstNums.push_back( std::stoi( s )) ; + std::cout << "Enter some more integers, separated by blanks!\n" ; + std::getline( std::cin , line ) ; + numberstrings.clear( ) ; + numberstrings = split( line , " " ) ; + for ( auto s : numberstrings ) + secondNums.push_back( std::stoi( s ) ) ; + std::set firstDiff , secondDiff ; + std::set firstSet( firstNums.begin( ) , firstNums.end( ) ) ; + std::set secondSet( secondNums.begin( ) , secondNums.end( ) ) ; + std::set_difference( firstSet.begin( ) , firstSet.end( ) , + secondSet.begin( ) , secondSet.end( ) , std::inserter( firstDiff , + firstDiff.begin( ) ) ) ; + std::set_difference( secondSet.begin( ) , secondSet.end( ) , + firstSet.begin( ) , firstSet.end( ) , std::inserter( secondDiff , + secondDiff.begin( ) )) ; + std::cout << "(( " ; + if ( firstDiff.size( ) > 0 ) { + std::copy( firstDiff.begin( ) , firstDiff.end( ) , + std::ostream_iterator( std::cout , " " ) ) ; + } + if ( secondDiff.size( ) > 0 ) { + std::cout << ") , ( " ; + std::copy( secondDiff.begin( ) , secondDiff.end( ) , + std::ostream_iterator( std::cout , " " )) ; + std::cout << " ))\n" ; + } + else { + std::cout << "))\n" ; + } + return 0 ; +} diff --git a/challenge-242/ulrich-rieke/cpp/ch-2.cpp b/challenge-242/ulrich-rieke/cpp/ch-2.cpp new file mode 100755 index 0000000000..d40538699d --- /dev/null +++ b/challenge-242/ulrich-rieke/cpp/ch-2.cpp @@ -0,0 +1,62 @@ +#include +#include +#include +#include + +std::vector split( const std::string & startline , + const std::string & sep ) { + std::vector separated ; + std::string::size_type start { 0 } ; + std::string::size_type pos ; + do { + pos = startline.find_first_of( sep , start ) ; + separated.push_back( startline.substr(start , pos - start )) ; + start = pos + 1 ; + } while ( pos != std::string::npos ) ; + return separated ; +} + +int myFlip( int num ) { + if (num == 0 ) + return 1 ; + else + return 0 ; +} + +int main( ) { + std::cout << "Enter some 0 or 1 , separated by blanks!\n" ; + std::string line ; + std::getline( std::cin , line ) ; + std::vector> matrix ; + std::vector numberstrings( split( line , " " ) ) ; + int len = numberstrings.size( ) ; + std::vector numbers ; + for ( auto s : numberstrings ) + numbers.push_back( std::stoi( s ) ) ; + matrix.push_back( numbers ) ; + for ( int i = 0 ; i < len - 1 ; i++ ) { + std::cout << "Please enter " << len << " numbers of 0 or 1 , " + << "separated by blanks!\n" ; + std::getline( std::cin , line ) ; + numberstrings = split( line , " " ) ; + numbers.clear( ) ; + for ( auto s : numberstrings ) + numbers.push_back( std::stoi( s ) ) ; + matrix.push_back( numbers ) ; + } + std::transform( matrix.begin( ) , matrix.end( ) , matrix.begin( ) , + []( auto & vec ) { std::reverse( vec.begin( ) , vec.end( ) ) ; + return vec ; } ) ; + std::transform( matrix.begin( ) , matrix.end( ) , matrix.begin( ) , + []( auto & vec ) { std::transform( vec.begin( ) , vec.end( ) , + vec.begin( ) , myFlip ) ; return vec ; } ) ; + std::cout << "(" ; + for ( auto & vec : matrix ) { + std::cout << "( " ; + for ( int i : vec ) + std::cout << i << " " ; + std::cout << ")" ; + } + std::cout << ")\n" ; + return 0 ; +} diff --git a/challenge-242/ulrich-rieke/haskell/ch-1.hs b/challenge-242/ulrich-rieke/haskell/ch-1.hs new file mode 100755 index 0000000000..a70738a3a7 --- /dev/null +++ b/challenge-242/ulrich-rieke/haskell/ch-1.hs @@ -0,0 +1,21 @@ +module Challenge242 + where +import qualified Data.Set as S + +solution :: [Int] -> [Int] -> ([Int] , [Int] ) +solution firstNums secondNums = ( S.toList firstDiffSet , + S.toList secondDiffSet ) + where + firstDiffSet = (S.fromList firstNums) S.\\ ( S.fromList secondNums ) + secondDiffSet = (S.fromList secondNums ) S.\\ (S.fromList firstNums ) + +main :: IO ( ) +main = do + putStrLn "Enter some integers, separated by blanks!" + firstNums <- getLine + putStrLn "Enter some more integers, separated by blanks!" + secondNums <- getLine + let firstNumbers = map read $ words firstNums + secondNumbers = map read $ words secondNums + thePair = solution firstNumbers secondNumbers + print thePair diff --git a/challenge-242/ulrich-rieke/haskell/ch-2.hs b/challenge-242/ulrich-rieke/haskell/ch-2.hs new file mode 100755 index 0000000000..4b60c26a21 --- /dev/null +++ b/challenge-242/ulrich-rieke/haskell/ch-2.hs @@ -0,0 +1,32 @@ +{-# LANGUAGE ScopedTypeVariables #-} +module Challenge242_2 + where + +enterNlines :: Int -> Int -> IO [String] +enterNlines n original + |n <= 0 = return [] + |otherwise = do + putStr ("Enter " ++ show n ++ " lines of " ++ + show original ++ " numbers") + putStrLn " 0 and 1" + numberstrings <- getLine + xs <- enterNlines ( n - 1 ) original + let ret = (numberstrings : xs) + return ret + +myFlip :: Int -> Int +myFlip n = if n == 1 then 0 else 1 + +convert :: [[Int]] -> [[Int]] +convert = map ( map myFlip . reverse ) + +main :: IO ( ) +main = do + putStrLn "Enter some 0 and 1 , separated by blanks!" ; + numberstrings <- getLine + let ct = length $ words numberstrings + (numbers :: [Int] ) = map read $ words numberstrings + additionalNumbers <- enterNlines ( ct - 1 ) ct + let allNums = numberstrings : additionalNumbers + allNumbers = map ( map read . words ) allNums + print $ convert allNumbers diff --git a/challenge-242/ulrich-rieke/perl/ch-1.pl b/challenge-242/ulrich-rieke/perl/ch-1.pl new file mode 100755 index 0000000000..4cb75399bd --- /dev/null +++ b/challenge-242/ulrich-rieke/perl/ch-1.pl @@ -0,0 +1,29 @@ +#!/usr/bin/perl ; +use strict ; +use warnings ; +use feature 'say' ; + +say "Enter some integers, separated by blanks!" ; +my $line = ; +chomp $line ; +my @firstNumbers = split( /\s/ , $line ) ; +say "Enter some more integers, separated by blanks!" ; +$line = ; +chomp $line ; +my @secondNumbers = split( /\s/ , $line ) ; +my %firstHash ; +my %secondHash ; +map { $firstHash{$_}++ } @firstNumbers ; +map { $secondHash{$_}++ } @secondNumbers ; +my @firstDiff = grep { not ( exists ( $secondHash{$_} ) ) } keys %firstHash ; +my @secondDiff = grep { not ( exists ( $firstHash{$_} ) ) } keys %secondHash ; +print "((" ; +if ( @firstDiff ) { + print join( ',' , @firstDiff ) ; +} +if ( @secondDiff ) { + say ") , (" . join( ',' , @secondDiff ) . "))" ; +} +else { + say "))" ; +} diff --git a/challenge-242/ulrich-rieke/perl/ch-2.pl b/challenge-242/ulrich-rieke/perl/ch-2.pl new file mode 100755 index 0000000000..af2da757dc --- /dev/null +++ b/challenge-242/ulrich-rieke/perl/ch-2.pl @@ -0,0 +1,40 @@ +#!/usr/bin/perl ; +use strict ; +use warnings ; +use feature 'say' ; + +sub myFlip { + my $number = shift ; + if ( $number == 0 ) { + return 1 ; + } + else { + return 0 ; + } +} + +say "Enter some 0 or 1 , separated by blanks!" ; +my $line = ; +chomp $line ; +my @numbers = split( /\s/ , $line ) ; +my $len = scalar( @numbers ) ; +my $counter = 0 ; +my @result ; +while ( $counter < $len - 1 ) { + my @reversed = reverse ( split( /\s/ , $line ) ) ; + my @flipped = map {myFlip( $_ )} @reversed ; + push @result , join( ',' , @flipped ) ; + say "Enter $len numbers 0 or 1 , separated by blanks!" ; + $line = ; + chomp $line ; + $counter++ ; +} +my @reversed = reverse ( split( /\s/ , $line ) ) ; +my @flipped = map {myFlip( $_ )} @reversed ; +push @result , join( ',' , @flipped ) ; +print "(" ; +for my $r( @result ) { + print "(" . $r . ")" . " " ; +} +say ")" + diff --git a/challenge-242/ulrich-rieke/raku/ch-1.raku b/challenge-242/ulrich-rieke/raku/ch-1.raku new file mode 100755 index 0000000000..64e7f2bf2f --- /dev/null +++ b/challenge-242/ulrich-rieke/raku/ch-1.raku @@ -0,0 +1,22 @@ +use v6 ; + +say "Enter some integers , separated by blanks!" ; +my $line = $*IN.get ; +my @firstNumbers = $line.words.map( {.Int} ) ; +say "Enter some more integers, separated by blanks!" ; +$line = $*IN.get ; +my @secondNumbers = $line.words.map( {.Int} ) ; +my $firstSet = @firstNumbers.Set ; +my $secondSet = @secondNumbers.Set ; +my $firstDiff = $firstSet (-) $secondSet ; +my $secondDiff = $secondSet (-) $firstSet ; +print "((" ; +if ( $firstDiff ) { + print $firstDiff.keys.sort ; +} +if ( $secondDiff ) { + say ") , (" ~ $secondDiff.keys.sort ~ "))" ; +} +else { + say "))" ; +} diff --git a/challenge-242/ulrich-rieke/raku/ch-2.raku b/challenge-242/ulrich-rieke/raku/ch-2.raku new file mode 100755 index 0000000000..893c882b79 --- /dev/null +++ b/challenge-242/ulrich-rieke/raku/ch-2.raku @@ -0,0 +1,34 @@ +use v6 ; + +sub myFlip( $number is copy ) { + if ( $number == 0 ) { + return 1 ; + } + else { + return 0 ; + } +} + +say "Enter some 0 or 1, separated by blanks!" ; +my $line = $*IN.get ; +my @numbers = $line.words ; +my $len = @numbers.elems ; +my $counter = 0 ; +my @matrix ; +while ( $counter != $len - 1 ) { + @matrix.push( $line ) ; + say "Enter $len elements of 0 or 1 , separated by blanks!" ; + $line = $*IN.get ; + $counter++ ; +} +@matrix.push( $line ) ; +my @result ; +for @matrix -> $l { + my $changed = $l.words.reverse.map( {myFlip( $_.Int)} ).join( ',' ) ; + @result.push( $changed ) ; +} +print "(" ; +for @result -> $r { + print "(" ~ $r ~ ")" ~ " "; +} +say ")" ; diff --git a/challenge-242/ulrich-rieke/rust/ch-1.rs b/challenge-242/ulrich-rieke/rust/ch-1.rs new file mode 100755 index 0000000000..3dc5874b32 --- /dev/null +++ b/challenge-242/ulrich-rieke/rust/ch-1.rs @@ -0,0 +1,29 @@ +use std::io ; +use std::collections::HashSet ; +fn main() { + println!("Enter some integers, separated by blanks!"); + let mut first_line : String = String::new( ) ; + io::stdin( ).read_line( &mut first_line ).unwrap( ) ; + let a_line : &str = &*first_line ; + let first_nums : Vec = a_line.split_whitespace( ).map( | s | + s.trim( ).parse::( ).unwrap( ) ).collect( ) ; + println!("Enter some more integers, separated by blanks!") ; + let mut second_line : String = String::new( ) ; + io::stdin( ).read_line( &mut second_line ).unwrap( ) ; + let b_line : &str = &*second_line ; + let second_nums : Vec = b_line.split_whitespace( ).map( | s | + s.trim( ).parse::( ).unwrap( ) ).collect( ) ; + let mut first_set : HashSet = HashSet::new( ) ; + let mut second_set : HashSet = HashSet::new( ) ; + for i in first_nums { + first_set.insert( i ) ; + } + for i in second_nums { + second_set.insert( i ) ; + } + let first_diff : HashSet<_> = second_set.difference( &first_set ) + .collect( ) ; + let second_diff : HashSet<_> = first_set.difference( &second_set ) + .collect( ) ; + println!("({:?} , {:?})" , second_diff , first_diff ) ; +} diff --git a/challenge-242/ulrich-rieke/rust/ch-2.rs b/challenge-242/ulrich-rieke/rust/ch-2.rs new file mode 100755 index 0000000000..bc3d1f38b0 --- /dev/null +++ b/challenge-242/ulrich-rieke/rust/ch-2.rs @@ -0,0 +1,41 @@ +use std::io ; + +fn main() { + println!("Enter some 0 or 1 , separated by blanks!"); + println!("Enter as many rows as there are numbers in the first row!") ; + let mut matrix : Vec> = Vec::new( ) ; + let mut inline : String = String::new( ) ; + io::stdin( ).read_line( &mut inline ).unwrap( ) ; + let entered_line : &str = &*inline ; + let first_nums : Vec = entered_line.split_whitespace( ).map( | s | + s.trim( ).parse::( ).unwrap( )).collect( ) ; + let len = first_nums.len( ) ; + matrix.push( first_nums ) ; + let mut counter : usize = 0 ; + while counter != len - 1 { + println!("Enter some more 0 and 1 , separated by blanks!") ; + let mut next_line : String = String::new( ) ; + io::stdin( ).read_line( &mut next_line ).unwrap( ) ; + let num_line : &str = &*next_line ; + let nums : Vec = num_line.split_whitespace( ).map( | s | + s.trim( ).parse::( ).unwrap( ) ).collect( ) ; + matrix.push( nums ) ; + counter += 1 ; + } + let mut new_matrix : Vec> = Vec::new( ) ; + for v in &mut matrix { + let sl = v.as_mut_slice( ) ; + sl.reverse( ) ; + let mut changed = sl.to_vec( ) ; + for i in 0..len { + if changed[ i ] == 0 { + changed[ i ] = 1 ; + } + else { + changed[ i ] = 0 ; + } + } + new_matrix.push( changed ) ; + } + println!("{:?}" , new_matrix ) ; +} diff --git a/stats/pwc-challenge-241.json b/stats/pwc-challenge-241.json new file mode 100644 index 0000000000..fc62085316 --- /dev/null +++ b/stats/pwc-challenge-241.json @@ -0,0 +1,695 @@ +{ + "legend" : { + "enabled" : 0 + }, + "tooltip" : { + "pointFormat" : "{point.name}: {point.y:f}
", + "followPointer" : 1, + "headerFormat" : "{series.name}
" + }, + "subtitle" : { + "text" : "[Champions: 37] Last updated at 2023-11-07 14:55:34 GMT" + }, + "drilldown" : { + "series" : [ + { + "data" : [ + [ + "Perl", + 2 + ], + [ + "Blog", + 2 + ] + ], + "id" : "Adam Russell", + "name" : "Adam Russell" + }, + { + "data" : [ + [ + "Perl", + 2 + ], + [ + "Raku", + 2 + ], + [ + "Blog", + 1 + ] + ], + "id" : "Ali Moradi", + "name" : "Ali Moradi" + }, + { + "data" : [ + [ + "Raku", + 2 + ], + [ + "Blog", + 1 + ] + ], + "name" : "Arne Sommer", + "id" : "Arne Sommer" + }, + { + "name" : "Athanasius", + "id" : "Athanasius", + "data" : [ + [ + "Perl", + 2 + ], + [ + "Raku", + 2 + ] + ] + }, + { + "id" : "Bob Lied", + "name" : "Bob Lied", + "data" : [ + [ + "Perl", + 2 + ], + [ + "Blog", + 1 + ] + ] + }, + { + "id" : "Bruce Gray", + "name" : "Bruce Gray", + "data" : [ + [ + "Raku", + 2 + ] + ] + }, + { + "name" : "Cheok-Yin Fung", + "id" : "Cheok-Yin Fung", + "data" : [ + [ + "Perl", + 2 + ] + ] + }, + { + "id" : "Dave Jacoby", + "name" : "Dave Jacoby", + "data" : [ + [ + "Perl", + 2 + ] + ] + }, + { + "data" : [ + [ + "Perl", + 2 + ] + ], + "name" : "David Ferrone", + "id" : "David Ferrone" + }, + { + "data" : [ + [ + "Perl", + 2 + ] + ], + "name" : "E. Choroba", + "id" : "E. Choroba" + }, + { + "id" : "Ian Rifkin", + "name" : "Ian Rifkin", + "data" : [ + [ + "Perl", + 2 + ], + [ + "Blog", + 1 + ] + ] + }, + { + "name" : "Jaldhar H. Vyas", + "id" : "Jaldhar H. Vyas", + "data" : [ + [ + "Perl", + 2 + ], + [ + "Raku", + 2 + ], + [ + "Blog", + 1 + ] + ] + }, + { + "id" : "Jan Krnavek", + "name" : "Jan Krnavek", + "data" : [ + [ + "Raku", + 2 + ] + ] + }, + { + "data" : [ + [ + "Perl", + 2 + ] + ], + "id" : "Jorg Sommrey", + "name" : "Jorg Sommrey" + }, + { + "name" : "Kjetil Skotheim", + "id" : "Kjetil Skotheim", + "data" : [ + [ + "Perl", + 2 + ] + ] + }, + { + "id" : "lacek96", + "name" : "lacek96", + "data" : [ + [ + "Perl", + 1 + ] + ] + }, + { + "name" : "librasteve", + "id" : "librasteve", + "data" : [ + [ + "Raku", + 2 + ] + ] + }, + { + "data" : [ + [ + "Perl", + 2 + ], + [ + "Raku", + 2 + ], + [ + "Blog", + 1 + ] + ], + "id" : "Lubos Kolouch", + "name" : "Lubos Kolouch" + }, + { + "name" : "Luca Ferrari", + "id" : "Luca Ferrari", + "data" : [ + [ + "Raku", + 2 + ], + [ + "Blog", + 8 + ] + ] + }, + { + "data" : [ + [ + "Raku", + 2 + ] + ], + "id" : "Mark Anderson", + "name" : "Mark Anderson" + }, + { + "data" : [ + [ + "Perl", + 2 + ] + ], + "id" : "Matthew Neleigh", + "name" : "Matthew Neleigh" + }, + { + "data" : [ + [ + "Perl", + 2 + ], + [ + "Blog", + 1 + ] + ], + "id" : "Matthias Muth", + "name" : "Matthias Muth" + }, + { + "data" : [ + [ + "Perl", + 2 + ] + ], + "name" : "Niels van Dijke", + "id" : "Niels van Dijke" + }, + { + "id" : "Packy Anderson", + "name" : "Packy Anderson", + "data" : [ + [ + "Perl", + 2 + ], + [ + "Raku", + 2 + ], + [ + "Blog", + 1 + ] + ] + }, + { + "id" : "Peter Campbell Smith", + "name" : "Peter Campbell Smith", + "data" : [ + [ + "Perl", + 2 + ], + [ + "Blog", + 1 + ] + ] + }, + { + "name" : "Peter Meszaros", + "id" : "Peter Meszaros", + "data" : [ + [ + "Perl", + 2 + ] + ] + }, + { + "name" : "Raghu R", + "id" : "Raghu R", + "data" : [ + [ + "Raku", + 2 + ] + ] + }, + { + "id" : "rcmlz", + "name" : "rcmlz", + "data" : [ + [ + "Raku", + 2 + ] + ] + }, + { + "name" : "Robbie Hatley", + "id" : "Robbie Hatley", + "data" : [ + [ + "Perl", + 2 + ], + [ + "Blog", + 1 + ] + ] + }, + { + "id" : "Robert Ransbottom", + "name" : "Robert Ransbottom", + "data" : [ + [ + "Raku", + 1 + ] + ] + }, + { + "data" : [ + [ + "Perl", + 2 + ], + [ + "Raku", + 2 + ], + [ + "Blog", + 1 + ] + ], + "name" : "Roger Bell_West", + "id" : "Roger Bell_West" + }, + { + "id" : "Simon Green", + "name" : "Simon Green", + "data" : [ + [ + "Perl", + 2 + ], + [ + "Blog", + 1 + ] + ] + }, + { + "data" : [ + [ + "Perl", + 2 + ] + ], + "name" : "Solathian", + "id" : "Solathian" + }, + { + "name" : "Thomas Kohler", + "id" : "Thomas Kohler", + "data" : [ + [ + "Perl", + 2 + ], + [ + "Blog", + 2 + ] + ] + }, + { + "id" : "Ulrich Rieke", + "name" : "Ulrich Rieke", + "data" : [ + [ + "Perl", + 2 + ], + [ + "Raku", + 2 + ] + ] + }, + { + "name" : "Vinod Kumar K", + "id" : "Vinod Kumar K", + "data" : [ + [ + "Perl", + 2 + ] + ] + }, + { + "name" : "W. Luis Mochan", + "id" : "W. Luis Mochan", + "data" : [ + [ + "Perl", + 2 + ], + [ + "Blog", + 1 + ] + ] + } + ] + }, + "plotOptions" : { + "series" : { + "dataLabels" : { + "enabled" : 1, + "format" : "{point.y}" + }, + "borderWidth" : 0 + } + }, + "series" : [ + { + "data" : [ + { + "name" : "Adam Russell", + "y" : 4, + "drilldown" : "Adam Russell" + }, + { + "name" : "Ali Moradi", + "y" : 5, + "drilldown" : "Ali Moradi" + }, + { + "name" : "Arne Sommer", + "y" : 3, + "drilldown" : "Arne Sommer" + }, + { + "y" : 4, + "name" : "Athanasius", + "drilldown" : "Athanasius" + }, + { + "drilldown" : "Bob Lied", + "y" : 3, + "name" : "Bob Lied" + }, + { + "name" : "Bruce Gray", + "y" : 2, + "drilldown" : "Bruce Gray" + }, + { + "drilldown" : "Cheok-Yin Fung", + "name" : "Cheok-Yin Fung", + "y" : 2 + }, + { + "drilldown" : "Dave Jacoby", + "name" : "Dave Jacoby", + "y" : 2 + }, + { + "name" : "David Ferrone", + "y" : 2, + "drilldown" : "David Ferrone" + }, + { + "name" : "E. Choroba", + "y" : 2, + "drilldown" : "E. Choroba" + }, + { + "name" : "Ian Rifkin", + "y" : 3, + "drilldown" : "Ian Rifkin" + }, + { + "name" : "Jaldhar H. Vyas", + "y" : 5, + "drilldown" : "Jaldhar H. Vyas" + }, + { + "drilldown" : "Jan Krnavek", + "name" : "Jan Krnavek", + "y" : 2 + }, + { + "drilldown" : "Jorg Sommrey", + "name" : "Jorg Sommrey", + "y" : 2 + }, + { + "name" : "Kjetil Skotheim", + "y" : 2, + "drilldown" : "Kjetil Skotheim" + }, + { + "name" : "lacek96", + "y" : 1, + "drilldown" : "lacek96" + }, + { + "y" : 2, + "name" : "librasteve", + "drilldown" : "librasteve" + }, + { + "drilldown" : "Lubos Kolouch", + "y" : 5, + "name" : "Lubos Kolouch" + }, + { + "y" : 10, + "name" : "Luca Ferrari", + "drilldown" : "Luca Ferrari" + }, + { + "drilldown" : "Mark Anderson", + "name" : "Mark Anderson", + "y" : 2 + }, + { + "name" : "Matthew Neleigh", + "y" : 2, + "drilldown" : "Matthew Neleigh" + }, + { + "name" : "Matthias Muth", + "y" : 3, + "drilldown" : "Matthias Muth" + }, + { + "name" : "Niels van Dijke", + "y" : 2, + "drilldown" : "Niels van Dijke" + }, + { + "drilldown" : "Packy Anderson", + "name" : "Packy Anderson", + "y" : 5 + }, + { + "drilldown" : "Peter Campbell Smith", + "y" : 3, + "name" : "Peter Campbell Smith" + }, + { + "drilldown" : "Peter Meszaros", + "name" : "Peter Meszaros", + "y" : 2 + }, + { + "drilldown" : "Raghu R", + "name" : "Raghu R", + "y" : 2 + }, + { + "drilldown" : "rcmlz", + "y" : 2, + "name" : "rcmlz" + }, + { + "name" : "Robbie Hatley", + "y" : 3, + "drilldown" : "Robbie Hatley" + }, + { + "drilldown" : "Robert Ransbottom", + "name" : "Robert Ransbottom", + "y" : 1 + }, + { + "drilldown" : "Roger Bell_West", + "name" : "Roger Bell_West", + "y" : 5 + }, + { + "drilldown" : "Simon Green", + "y" : 3, + "name" : "Simon Green" + }, + { + "name" : "Solathian", + "y" : 2, + "drilldown" : "Solathian" + }, + { + "drilldown" : "Thomas Kohler", + "y" : 4, + "name" : "Thomas Kohler" + }, + { + "name" : "Ulrich Rieke", + "y" : 4, + "drilldown" : "Ulrich Rieke" + }, + { + "name" : "Vinod Kumar K", + "y" : 2, + "drilldown" : "Vinod Kumar K" + }, + { + "name" : "W. Luis Mochan", + "y" : 3, + "drilldown" : "W. Luis Mochan" + } + ], + "colorByPoint" : 1, + "name" : "The Weekly Challenge - 241" + } + ], + "xAxis" : { + "type" : "category" + }, + "chart" : { + "type" : "column" + }, + "yAxis" : { + "title" : { + "text" : "Total Solutions" + } + }, + "title" : { + "text" : "The Weekly Challenge - 241" + } +} diff --git a/stats/pwc-current.json b/stats/pwc-current.json index fe9d688c86..165f742958 100644 --- a/stats/pwc-current.json +++ b/stats/pwc-current.json @@ -1,172 +1,52 @@ { + "xAxis" : { + "type" : "category" + }, + "legend" : { + "enabled" : 0 + }, + "subtitle" : { + "text" : "[Champions: 17] Last updated at 2023-11-07 15:05:42 GMT" + }, + "title" : { + "text" : "The Weekly Challenge - 242" + }, + "plotOptions" : { + "series" : { + "dataLabels" : { + "format" : "{point.y}", + "enabled" : 1 + }, + "borderWidth" : 0 + } + }, + "yAxis" : { + "title" : { + "text" : "Total Solutions" + } + }, "drilldown" : { "series" : [ { - "id" : "Adam Russell", - "name" : "Adam Russell", + "id" : "Clifton Wood", + "name" : "Clifton Wood", "data" : [ - [ - "Perl", - 2 - ], - [ - "Blog", - 2 - ] - ] - }, - { - "id" : "Ali Moradi", - "name" : "Ali Moradi", - "data" : [ - [ - "Perl", - 2 - ], [ "Raku", 2 - ], - [ - "Blog", - 1 ] ] }, { - "data" : [ - [ - "Raku", - 2 - ], - [ - "Blog", - 1 - ] - ], - "id" : "Arne Sommer", - "name" : "Arne Sommer" - }, - { - "data" : [ - [ - "Perl", - 2 - ], - [ - "Raku", - 2 - ] - ], - "name" : "Athanasius", - "id" : "Athanasius" - }, - { - "id" : "Bob Lied", - "name" : "Bob Lied", - "data" : [ - [ - "Perl", - 2 - ], - [ - "Blog", - 1 - ] - ] - }, - { - "data" : [ - [ - "Raku", - 2 - ] - ], - "name" : "Bruce Gray", - "id" : "Bruce Gray" - }, - { - "data" : [ - [ - "Perl", - 2 - ] - ], - "id" : "Cheok-Yin Fung", - "name" : "Cheok-Yin Fung" - }, - { - "data" : [ - [ - "Perl", - 2 - ] - ], - "id" : "Dave Jacoby", - "name" : "Dave Jacoby" - }, - { - "data" : [ - [ - "Perl", - 2 - ] - ], + "id" : "David Ferrone", "name" : "David Ferrone", - "id" : "David Ferrone" - }, - { "data" : [ [ "Perl", 2 ] - ], - "name" : "E. Choroba", - "id" : "E. Choroba" - }, - { - "data" : [ - [ - "Perl", - 2 - ], - [ - "Blog", - 1 - ] - ], - "name" : "Ian Rifkin", - "id" : "Ian Rifkin" - }, - { - "id" : "Jaldhar H. Vyas", - "name" : "Jaldhar H. Vyas", - "data" : [ - [ - "Perl", - 2 - ], - [ - "Raku", - 2 - ], - [ - "Blog", - 1 - ] ] }, - { - "data" : [ - [ - "Raku", - 2 - ] - ], - "id" : "Jan Krnavek", - "name" : "Jan Krnavek" - }, { "data" : [ [ @@ -174,60 +54,30 @@ 2 ] ], - "name" : "Jorg Sommrey", - "id" : "Jorg Sommrey" + "id" : "E. Choroba", + "name" : "E. Choroba" }, { - "data" : [ - [ - "Perl", - 2 - ] - ], - "id" : "Kjetil Skotheim", - "name" : "Kjetil Skotheim" - }, - { - "name" : "lacek96", - "id" : "lacek96", "data" : [ [ "Perl", 1 - ] - ] - }, - { - "data" : [ - [ - "Raku", - 2 - ] - ], - "id" : "librasteve", - "name" : "librasteve" - }, - { - "data" : [ - [ - "Perl", - 2 ], [ "Raku", - 2 + 1 ], [ "Blog", 1 ] ], - "name" : "Lubos Kolouch", - "id" : "Lubos Kolouch" + "name" : "Laurent Rosenfeld", + "id" : "Laurent Rosenfeld" }, { - "name" : "Luca Ferrari", "id" : "Luca Ferrari", + "name" : "Luca Ferrari", "data" : [ [ "Raku", @@ -240,14 +90,14 @@ ] }, { - "id" : "Mark Anderson", - "name" : "Mark Anderson", "data" : [ [ "Raku", 2 ] - ] + ], + "name" : "Mark Anderson", + "id" : "Mark Anderson" }, { "data" : [ @@ -256,8 +106,8 @@ 2 ] ], - "name" : "Matthew Neleigh", - "id" : "Matthew Neleigh" + "id" : "Matthew Neleigh", + "name" : "Matthew Neleigh" }, { "data" : [ @@ -266,18 +116,8 @@ 2 ] ], - "name" : "Matthias Muth", - "id" : "Matthias Muth" - }, - { "name" : "Niels van Dijke", - "id" : "Niels van Dijke", - "data" : [ - [ - "Perl", - 2 - ] - ] + "id" : "Niels van Dijke" }, { "id" : "Packy Anderson", @@ -298,52 +138,18 @@ ] }, { - "id" : "Peter Campbell Smith", - "name" : "Peter Campbell Smith", "data" : [ [ "Perl", 2 - ], - [ - "Blog", - 1 - ] - ] - }, - { - "name" : "Peter Meszaros", - "id" : "Peter Meszaros", - "data" : [ - [ - "Perl", - 2 - ] - ] - }, - { - "data" : [ - [ - "Raku", - 2 - ] - ], - "name" : "Raghu R", - "id" : "Raghu R" - }, - { - "data" : [ - [ - "Raku", - 2 ] ], - "name" : "rcmlz", - "id" : "rcmlz" + "id" : "Paulo Custodio", + "name" : "Paulo Custodio" }, { - "name" : "Robbie Hatley", - "id" : "Robbie Hatley", + "name" : "Peter Campbell Smith", + "id" : "Peter Campbell Smith", "data" : [ [ "Perl", @@ -356,56 +162,42 @@ ] }, { - "name" : "Robert Ransbottom", - "id" : "Robert Ransbottom", - "data" : [ - [ - "Raku", - 1 - ] - ] - }, - { + "id" : "Robbie Hatley", + "name" : "Robbie Hatley", "data" : [ [ "Perl", 2 ], - [ - "Raku", - 2 - ], [ "Blog", 1 ] - ], - "name" : "Roger Bell_West", - "id" : "Roger Bell_West" + ] }, { - "id" : "Simon Green", - "name" : "Simon Green", + "name" : "Roger Bell_West", + "id" : "Roger Bell_West", "data" : [ [ "Perl", 2 ], [ - "Blog", - 1 + "Raku", + 2 ] ] }, { + "id" : "Simon Proctor", + "name" : "Simon Proctor", "data" : [ [ - "Perl", - 2 + "Raku", + 1 ] - ], - "id" : "Solathian", - "name" : "Solathian" + ] }, { "data" : [ @@ -422,6 +214,8 @@ "id" : "Thomas Kohler" }, { + "id" : "Ulrich Rieke", + "name" : "Ulrich Rieke", "data" : [ [ "Perl", @@ -431,18 +225,6 @@ "Raku", 2 ] - ], - "name" : "Ulrich Rieke", - "id" : "Ulrich Rieke" - }, - { - "id" : "Vinod Kumar K", - "name" : "Vinod Kumar K", - "data" : [ - [ - "Perl", - 2 - ] ] }, { @@ -456,236 +238,110 @@ 1 ] ], - "name" : "W. Luis Mochan", - "id" : "W. Luis Mochan" + "id" : "W. Luis Mochan", + "name" : "W. Luis Mochan" } ] }, - "xAxis" : { - "type" : "category" - }, - "plotOptions" : { - "series" : { - "dataLabels" : { - "enabled" : 1, - "format" : "{point.y}" - }, - "borderWidth" : 0 - } - }, - "legend" : { - "enabled" : 0 - }, - "tooltip" : { - "headerFormat" : "{series.name}
", - "pointFormat" : "{point.name}: {point.y:f}
", - "followPointer" : 1 - }, "series" : [ { "data" : [ { - "drilldown" : "Adam Russell", - "name" : "Adam Russell", - "y" : 4 - }, - { - "name" : "Ali Moradi", - "y" : 5, - "drilldown" : "Ali Moradi" - }, - { - "drilldown" : "Arne Sommer", - "y" : 3, - "name" : "Arne Sommer" - }, - { - "drilldown" : "Athanasius", - "y" : 4, - "name" : "Athanasius" - }, - { - "drilldown" : "Bob Lied", - "name" : "Bob Lied", - "y" : 3 - }, - { - "drilldown" : "Bruce Gray", + "name" : "Clifton Wood", "y" : 2, - "name" : "Bruce Gray" + "drilldown" : "Clifton Wood" }, { - "drilldown" : "Cheok-Yin Fung", "y" : 2, - "name" : "Cheok-Yin Fung" - }, - { - "drilldown" : "Dave Jacoby", - "name" : "Dave Jacoby", - "y" : 2 - }, - { "drilldown" : "David Ferrone", - "name" : "David Ferrone", - "y" : 2 - }, - { - "drilldown" : "E. Choroba", - "name" : "E. Choroba", - "y" : 2 - }, - { - "drilldown" : "Ian Rifkin", - "y" : 3, - "name" : "Ian Rifkin" - }, - { - "name" : "Jaldhar H. Vyas", - "y" : 5, - "drilldown" : "Jaldhar H. Vyas" - }, - { - "drilldown" : "Jan Krnavek", - "y" : 2, - "name" : "Jan Krnavek" + "name" : "David Ferrone" }, { - "name" : "Jorg Sommrey", "y" : 2, - "drilldown" : "Jorg Sommrey" - }, - { - "name" : "Kjetil Skotheim", - "y" : 2, - "drilldown" : "Kjetil Skotheim" - }, - { - "name" : "lacek96", - "y" : 1, - "drilldown" : "lacek96" - }, - { - "name" : "librasteve", - "y" : 2, - "drilldown" : "librasteve" + "drilldown" : "E. Choroba", + "name" : "E. Choroba" }, { - "name" : "Lubos Kolouch", - "y" : 5, - "drilldown" : "Lubos Kolouch" + "name" : "Laurent Rosenfeld", + "drilldown" : "Laurent Rosenfeld", + "y" : 3 }, { + "y" : 10, "drilldown" : "Luca Ferrari", - "name" : "Luca Ferrari", - "y" : 10 + "name" : "Luca Ferrari" }, { - "y" : 2, "name" : "Mark Anderson", - "drilldown" : "Mark Anderson" - }, - { - "y" : 2, - "name" : "Matthew Neleigh", - "drilldown" : "Matthew Neleigh" + "drilldown" : "Mark Anderson", + "y" : 2 }, { + "drilldown" : "Matthew Neleigh", "y" : 2, - "name" : "Matthias Muth", - "drilldown" : "Matthias Muth" + "name" : "Matthew Neleigh" }, { - "name" : "Niels van Dijke", "y" : 2, - "drilldown" : "Niels van Dijke" + "drilldown" : "Niels van Dijke", + "name" : "Niels van Dijke" }, { - "drilldown" : "Packy Anderson", "name" : "Packy Anderson", + "drilldown" : "Packy Anderson", "y" : 5 }, { - "y" : 3, - "name" : "Peter Campbell Smith", - "drilldown" : "Peter Campbell Smith" - }, - { - "drilldown" : "Peter Meszaros", - "y" : 2, - "name" : "Peter Meszaros" - }, - { - "name" : "Raghu R", + "drilldown" : "Paulo Custodio", "y" : 2, - "drilldown" : "Raghu R" + "name" : "Paulo Custodio" }, { - "name" : "rcmlz", - "y" : 2, - "drilldown" : "rcmlz" + "y" : 3, + "drilldown" : "Peter Campbell Smith", + "name" : "Peter Campbell Smith" }, { "drilldown" : "Robbie Hatley", "y" : 3, "name" : "Robbie Hatley" }, - { - "y" : 1, - "name" : "Robert Ransbottom", - "drilldown" : "Robert Ransbottom" - }, { "name" : "Roger Bell_West", - "y" : 5, + "y" : 4, "drilldown" : "Roger Bell_West" }, { - "name" : "Simon Green", - "y" : 3, - "drilldown" : "Simon Green" - }, - { - "drilldown" : "Solathian", - "name" : "Solathian", - "y" : 2 + "y" : 1, + "drilldown" : "Simon Proctor", + "name" : "Simon Proctor" }, { + "y" : 4, "drilldown" : "Thomas Kohler", - "name" : "Thomas Kohler", - "y" : 4 + "name" : "Thomas Kohler" }, { "y" : 4, - "name" : "Ulrich Rieke", - "drilldown" : "Ulrich Rieke" + "drilldown" : "Ulrich Rieke", + "name" : "Ulrich Rieke" }, { - "drilldown" : "Vinod Kumar K", - "name" : "Vinod Kumar K", - "y" : 2 - }, - { - "drilldown" : "W. Luis Mochan", "name" : "W. Luis Mochan", + "drilldown" : "W. Luis Mochan", "y" : 3 } ], "colorByPoint" : 1, - "name" : "The Weekly Challenge - 241" + "name" : "The Weekly Challenge - 242" } ], - "yAxis" : { - "title" : { - "text" : "Total Solutions" - } + "tooltip" : { + "followPointer" : 1, + "pointFormat" : "{point.name}: {point.y:f}
", + "headerFormat" : "{series.name}
" }, "chart" : { "type" : "column" - }, - "subtitle" : { - "text" : "[Champions: 37] Last updated at 2023-11-06 00:16:30 GMT" - }, - "title" : { - "text" : "The Weekly Challenge - 241" } } diff --git a/stats/pwc-language-breakdown-summary.json b/stats/pwc-language-breakdown-summary.json index 65eebda96e..b90b952316 100644 --- a/stats/pwc-language-breakdown-summary.json +++ b/stats/pwc-language-breakdown-summary.json @@ -1,61 +1,61 @@ { - "xAxis" : { - "labels" : { - "style" : { - "fontFamily" : "Verdana, sans-serif", - "fontSize" : "13px" - } + "yAxis" : { + "title" : { + "text" : null }, - "type" : "category" - }, - "legend" : { - "enabled" : "false" + "min" : 0 }, "tooltip" : { "pointFormat" : "{point.y:.0f}" }, "series" : [ { - "name" : "Contributions", + "dataLabels" : { + "format" : "{point.y:.0f}", + "rotation" : -90, + "align" : "right", + "enabled" : "true", + "style" : { + "fontSize" : "13px", + "fontFamily" : "Verdana, sans-serif" + }, + "y" : 10, + "color" : "#FFFFFF" + }, "data" : [ [ "Blog", - 4145 + 4161 ], [ "Perl", - 12437 + 12462 ], [ "Raku", - 7174 + 7188 ] ], - "dataLabels" : { - "align" : "right", - "format" : "{point.y:.0f}", - "rotation" : -90, - "color" : "#FFFFFF", - "style" : { - "fontSize" : "13px", - "fontFamily" : "Verdana, sans-serif" - }, - "y" : 10, - "enabled" : "true" - } + "name" : "Contributions" } ], - "yAxis" : { - "min" : 0, - "title" : { - "text" : null - } - }, "chart" : { "type" : "column" }, + "xAxis" : { + "type" : "category", + "labels" : { + "style" : { + "fontFamily" : "Verdana, sans-serif", + "fontSize" : "13px" + } + } + }, + "legend" : { + "enabled" : "false" + }, "subtitle" : { - "text" : "Last updated at 2023-11-06 00:16:30 GMT" + "text" : "Last updated at 2023-11-07 15:05:42 GMT" }, "title" : { "text" : "The Weekly Challenge Contributions [2019 - 2023]" diff --git a/stats/pwc-language-breakdown.json b/stats/pwc-language-breakdown.json index d474c1ee34..bc83f6e268 100644 --- a/stats/pwc-language-breakdown.json +++ b/stats/pwc-language-breakdown.json @@ -2,4367 +2,15 @@ "chart" : { "type" : "column" }, - "yAxis" : { - "title" : { - "text" : "Total Solutions" - } - }, - "title" : { - "text" : "The Weekly Challenge Language" - }, - "subtitle" : { - "text" : "Click the columns to drilldown the language breakdown. Last updated at 2023-11-06 00:16:30 GMT" - }, - "drilldown"