Ok fellow coders, here's a problem for you - Mustang Evolution

Go Back   Mustang Evolution > Off Topic Forums > The Bar



Reply
 
Thread Tools Search this Thread
Please support our sponsors and let them know you heard about them here!
Old 01-04-2010, 03:46 PM   #1
15.3 Second V8 Killer Yo
Legacy
Regular
 
PureVenom's Avatar
 
Join Date: Aug 2004
Region: Louisiana
Posts: 7,212
Send a message via AIM to PureVenom Send a message via MSN to PureVenom Send a message via Yahoo to PureVenom
Ok fellow coders, here's a problem for you

Ok, I am working on a program to allow me to generate an 8 person bracket based on a list of names. I have a general flow in mind, but I'm having a hard time wrapping my head around the algorithm in general.

Anyhow, here's the problem details:

A list of names are gathered. Each name is allowed to be in 1 or more brackets.

For example, person A may want to be included in 4 brackets. person B 2 brackets. And person C only wants 1.

The goal is to take the complete list of names and split them into groups of 8 where all 8 people in the group are unique.

If there are remaining names left over, that's fine. Bye's can be inserted into groups of 8 to allow the filling of final bracket.

The main constraints are
1. each group of 8 must contain 8 unique names.
2. People that only want to be included in 1 bracket need to be guaranteed a spot. Those entered in more than one need to also be guaranteed at least 1 spot as well.
3. There is no set maximum number of brackets to be created.
4. There is no set maximum number of brackets a person could request to be a part of.


Anyhow, I'd like to hear some of your thoughts into the algorithm that should be used. I think I'm close, but I'm just not feeling it right now.
__________________
"When I know more, I'll be forthcoming. Or I won't be forthcoming, and I'll be honestly deceptive." - Les Miles
PureVenom is offline   Reply With Quote
Sponsored Links
Advertisement
 
Old 01-04-2010, 04:18 PM   #2
Moderator Emeritus
Legacy
Regular
 
SpectorV's Avatar
 
Join Date: May 2003
Region: Alabama
Posts: 26,049
Send a message via AIM to SpectorV
Re: Ok fellow coders, here's a problem for you

define a bracket and why one person would want to be in more than one bracket at a time, since they can only be in each bracket once.

what is the structure (visually) of each 8 person bracket (the break down)

further describe the bye setup and bracket of bye's
__________________
2003 Cobra Vert (Redfire) #3938 of 5082 @ 05/27/2003
472rwhp/493rwtq -Modification List - Dyno Sheet
2012 Mustang 3.7L M6 (Kona Blue)
2011 Ford Edge Sport (Red Metallic)
SpectorV is offline   Reply With Quote
Old 01-04-2010, 04:30 PM   #3
15.3 Second V8 Killer Yo
Legacy
Regular
 
PureVenom's Avatar
 
Join Date: Aug 2004
Region: Louisiana
Posts: 7,212
Send a message via AIM to PureVenom Send a message via MSN to PureVenom Send a message via Yahoo to PureVenom
Re: Ok fellow coders, here's a problem for you

This is for a bowling bracket. See, when bowling in leagues or tournaments, a person can enter brackets. IT typically costs $5 per entry and you can enter as many as you want. If there are not enough feesable brackets to fill your request, you are refunded the number you couldn't fit into.

Basically, it is a 8 person bracket where game 1 is used for round 1. Game 2 is used for round 2. And game 3 is used for round 3. The winner of each round moves on, single elimination.

Byes are used when there aren't 8 people to fill a bracket. This is used to create as many brackets as possible. However, you don't necessarily want to have a bracket of mostly byes. You'd only want to have 1, and at most 2 byes per bracket. but, the idea is to spread out the byes to try and make it so there is only 1 per bracket if possible.

The visual breakdown of a bracket is like this:

__________________
"When I know more, I'll be forthcoming. Or I won't be forthcoming, and I'll be honestly deceptive." - Les Miles
PureVenom is offline   Reply With Quote
Sponsored Links
Advertisement
 
Old 01-04-2010, 04:43 PM   #4
15.3 Second V8 Killer Yo
Legacy
Regular
 
PureVenom's Avatar
 
Join Date: Aug 2004
Region: Louisiana
Posts: 7,212
Send a message via AIM to PureVenom Send a message via MSN to PureVenom Send a message via Yahoo to PureVenom
Re: Ok fellow coders, here's a problem for you

The part that I think I keep tripping over is the fact that there is no set number of brackets to be created. The concept of splitting a list into groups of 8 unique names is not that big of a deal. The problem I'm having is making sure everyone gets included at least once (although there are situations where someone could be left out if not enough entries).

I'm not sure if I should just sort my list ascending based on the number of brackets someone wants to ensure the 1's get used first or descending to use the multi entrants first...or if I should just leave the list sorted by when the person came to sign up and pick and choose names from there.
__________________
"When I know more, I'll be forthcoming. Or I won't be forthcoming, and I'll be honestly deceptive." - Les Miles
PureVenom is offline   Reply With Quote
Reply

Lower Navigation
Go Back   Mustang Evolution > Off Topic Forums > The Bar

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Hi Fellow Collectors OneCarnut New Member Introductions & Greetings 7 01-22-2008 09:04 AM
hello fellow stangers 91GTVERT New Member Introductions & Greetings 10 11-17-2005 01:05 PM
run-in with fellow v6 stanger Kyle The Bar 23 05-07-2005 07:56 PM
help a fellow stanger out! WhiteStang99 The Bar 32 08-24-2004 10:56 PM
Raced a fellow V6 last night el cheapo Pre-2005 V6 Mustang 21 07-30-2003 01:16 PM

» Like Us On Facebook



04:36 AM


Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2017, vBulletin Solutions, Inc.
Content Relevant URLs by vBSEO 3.6.0

MustangEvolution.com is in no way associated with or endorsed by Ford Motor Company.