Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re^3: Perl Solution to Spotify Programming Puzzle

by repellent (Priest)
on Aug 28, 2011 at 08:42 UTC ( [id://922860]=note: print w/replies, xml ) Need Help??


in reply to Re^2: Perl Solution to Spotify Programming Puzzle
in thread Perl Solution to Spotify Programming Puzzle

Actual:
> Bilateral2.pl 7 71 34 71 1001 72 1002 73 1003 1001 2000 1002 2000 1003 2000 ^D 3 1002 71 1003

Expected:
4 1001 1002 1003 71 or 34

Replies are listed 'Best First'.
Re^4: Perl Solution to Spotify Programming Puzzle
by BrowserUk (Patriarch) on Aug 28, 2011 at 12:00 UTC

    Sorry, but I think you are wrong here and that my actual solution is correct.

    / 1001 - 71 - 34 2000 - 1002 - 72 \ 1003 - 73

    If you have 1003, you don't need 73 or 2000.

    If you have 1002, you don't need 72 (or 2000).

    If you have 71, you don't need 34 or 1001.


    Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
    "Science is about questioning the status quo. Questioning authority".
    In the absence of evidence, opinion is indistinguishable from prejudice.
      From my interpretation of the problem, we need a representative from each project:

        The situation is that each of the many but small projects is handled by a two-person team ...

        However, money is tight and a new policy has been created: the CEO wants at least one person from each project, ...

      Given the input, Bilateral2.pl hasn't considered project [1001 2000]. The output has no representative from that team. (The output did include members that worked with team [1001 2000] though).

        You're right of course.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://922860]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (8)
As of 2024-04-23 10:35 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found