Author Topic: Points/Formula help please  (Read 1093 times)

RogerRedHat

  • Newbie
  • *
  • Posts: 2
    • View Profile
Points/Formula help please
« on: April 05, 2009, 02:32:00 AM »
I'd like a formula for the following league points format:

Everyone receives 2 points just for showing up.

The final table of nine will receive a total number of points as follows:

1st   15 pts (2 points for showing up + 13points for winning)
2nd  12pts
3rd   10pts
4th   8pts
5th   7pts
6th   6pts
7th   5pts
8th   4pts
9th   3pts
 
Everything I've tried so far as failed quite spectacularly so I'd appreciate any help.  Thanks in advance.

Johno

  • Full Member
  • ***
  • Posts: 191
    • View Profile
    • The Poker Leaderbaord
Re: Points/Formula help please
« Reply #1 on: April 05, 2009, 04:55:59 AM »
assign("v", switch(r, 1, 13, 2, 10, 3, 8, 4, 6, 5, 5, 6, 4, 7, 3, 8, 2, 9, 1))
v + 2

Cheers.
My League Website - Joomla Component for TD. Now available for Joomla 1.5, 1.7 & 2.5

RogerRedHat

  • Newbie
  • *
  • Posts: 2
    • View Profile
Re: Points/Formula help please
« Reply #2 on: April 06, 2009, 08:17:30 AM »
Thanks for that John, unfortunately that doesn't seem to work? Anything Else I might try?

badbeat

  • Full Member
  • ***
  • Posts: 114
    • View Profile
Re: Points/Formula help please
« Reply #3 on: April 06, 2009, 09:38:18 AM »
This should be what you want,

2 + switch(r ,1,13, 2,10, 3,8, 4,6, 5,5, 6,4, 7,3, 8,2, 9,1)

Corey Cooper

  • Administrator
  • Hero Member
  • *****
  • Posts: 5427
    • View Profile
Re: Points/Formula help please
« Reply #4 on: April 06, 2009, 12:02:34 PM »
Both seem to work for me...