Cody

# Problem 1883. GJam 2013 China Event: Happy Teams 100 Pairs

Solution 320975

Submitted on 19 Sep 2013 by Tobias Schäfer
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

### Test Suite

Test Status Code Input and Output
1   Pass

ans = 1

2   Pass
%% names={{'Dr_Evil' 'Devastation'} {'Dr_Evil' 'Southpaw'} {'Dr_Evil' 'Lagomorph'} {'Dr_Evil' 'Rampage'} {'Dr_Evil' 'Unicron'} {'Dr_Evil' 'Magenta'} {'Dr_Evil' 'Silver_Swan'} {'Dr_Evil' 'Zaladane'} {'Dr_Evil' 'Jason_Kreis'} {'Dr_Evil' 'Lotso'} }; exp=1; TF=Make_Teams(names); assert(TF==exp)

ans = 1

3   Pass

ans = 0

4   Pass

ans = 1

5   Pass

ans = 0

6   Pass
%% names={{'Princess_Python' 'Abominatrix'} {'Mai_Shen' 'Devastation'} {'Abominatrix' 'Mai_Shen'} {'Devastation' 'Princess_Python'} }; exp=1; TF=Make_Teams(names); assert(TF==exp)

ans = 1

7   Pass

ans = 1

8   Pass

ans = 0

9   Pass

ans = 1

10   Pass
%% names={{'Spider_Girl' 'Blue_Snowman'} {'Blue_Snowman' 'Roulette'} {'Roulette' 'Spider_Girl'} }; exp=0; TF=Make_Teams(names); assert(TF==exp)

ans = 0

11   Pass
%% names={{'Rampage' 'Fury_Leika'} {'Tigress' 'Princess_Python'} {'Syndrome' 'Animora'} {'Maxima' 'Prank'} {'Queen_Of_Fables' 'Queen_Bee'} {'Queen_Of_Fables' 'Doctor_Cyber'} {'Magpie' 'Queen_Bee'} {'Shimmer' 'Golddigger'} {'Rampage' 'Queen_Clea'} {'Magpie' 'Abominatrix'} {'Maxima' 'Titania'} {'Tigress' 'Prank'} {'Decay' 'Prank'} {'Spider_Girl' 'Jewelee'} {'Magpie' 'Princess_Python'} {'Eviless' 'Abominatrix'} {'Shimmer' 'Doctor_Cyber'} {'Star_Sapphire' 'Animora'} {'Star_Sapphire' 'Jinx'} {'Yellowjacket' 'Blue_Snowman'} {'Star_Sapphire' 'Queen_Clea'} {'Black_Mamba' 'Jewelee'} {'Star_Sapphire' 'Blue_Snowman'} {'Magpie' 'Titania'} {'Spider_Girl' 'Abominatrix'} {'Lashina' 'Dr_Evil'} {'Margaret_Love' 'Prank'} {'Lotso' 'Fury_Leika'} {'Maxima' 'Abominatrix'} {'Decay' 'Queen_Clea'} {'Star_Sapphire' 'Doctor_Cyber'} {'Maxima' 'Queen_Clea'} {'Yellowjacket' 'Abominatrix'} {'Syndrome' 'Sun_Girl'} {'Rampage' 'Windfall'} {'Lotso' 'Titania'} {'Syndrome' 'Blue_Snowman'} {'Plastique' 'Queen_Clea'} {'Magpie' 'Sun_Girl'} {'Lady_Clay' 'Queen_Clea'} {'Eviless' 'Princess_Python'} {'Fake_Thomas_Jefferson' 'Blue_Snowman'} {'Rampage' 'Animora'} {'Fake_Thomas_Jefferson' 'Sun_Girl'} {'Star_Sapphire' 'Abominatrix'} {'Black_Mamba' 'Poundcakes'} {'Plastique' 'Sun_Girl'} {'Lady_Clay' 'Titania'} {'Fake_Thomas_Jefferson' 'Windfall'} {'Shimmer' 'Osira'} {'Lady_Clay' 'Ursa'} {'Syndrome' 'Queen_Bee'} {'Maxima' 'Blue_Snowman'} {'Lady_Clay' 'Dr_Evil'} {'Decay' 'Amy_Madison'} {'Tigress' 'Jinx'} {'Spider_Girl' 'Jinx'} {'Margaret_Love' 'Titania'} {'Star_Sapphire' 'Poundcakes'} {'Plastique' 'Doctor_Cyber'} {'Black_Mamba' 'Amy_Madison'} {'Tigress' 'Titania'} {'Lashina' 'Golddigger'} {'Eviless' 'Dr_Evil'} {'Magenta' 'Windfall'} {'Yellowjacket' 'Princess_Python'} {'Syndrome' 'Prank'} {'Shimmer' 'Poundcakes'} {'Decay' 'Fury_Leika'} {'Decay' 'Windfall'} {'Black_Mamba' 'Golddigger'} {'Rampage' 'Abominatrix'} {'Syndrome' 'Golddigger'} {'Maxima' 'Fury_Leika'} {'Eviless' 'Jewelee'} {'Lashina' 'Blue_Snowman'} {'Lady_Clay' 'Jinx'} {'Lady_Clay' 'Windfall'} {'Magpie' 'Ursa'} {'Eviless' 'Prank'} {'Tigress' 'Abominatrix'} {'Star_Sapphire' 'Eviless'} {'Tigress' 'Fury_Leika'} {'Magenta' 'Ursa'} {'Yellowjacket' 'Jewelee'} {'Yellowjacket' 'Ursa'} {'Plastique' 'Osira'} {'Tigress' 'Sun_Girl'} {'Tigress' 'Golddigger'} {'Spider_Girl' 'Windfall'} {'Fake_Thomas_Jefferson' 'Amy_Madison'} {'Magenta' 'Fury_Leika'} {'Star_Sapphire' 'Amy_Madison'} {'Magenta' 'Blue_Snowman'} {'Plastique' 'Ursa'} {'Fake_Thomas_Jefferson' 'Abominatrix'} {'Lotso' 'Jewelee'} {'Lotso' 'Jinx'} {'Maxima' 'Animora'} {'Magenta' 'Sun_Girl'} }; exp=0; TF=Make_Teams(names); assert(TF==exp)

ans = 0

12   Pass

ans = 0

13   Pass

ans = 1

14   Fail