• Post Reply Bookmark Topic Watch Topic
  • New Topic

help with making a football league system please..  RSS feed

Scott Cajun
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hello, i like the mooses =D

ok firstly this mini project does not involve any object oorientated java.. but instead using procedural style.. with arrays, loops, for loops, while loops, methods, etc..

ok well there's 4 teams, each plays each other twice (home and away) so theres 12 games in total (6 weeks)

well baisically the user inputs the teams to play each other, and the program randomly gets the scores and records the stats ready for output in the league table.

now it seems good so far but then after those games have been played, and the next games are to be selected, i need a way to stop the user from selecting games that have already been played before (don't want repeat matches..)

i was given the idea of a long list of boolean variables of all the different match combinations, and when one is played it sets the respective variable to 'true' so it can't be played again. Seems like a good idea but i can't get it to work properly! I was hoping someone could take a look and try and see what im doing wrong/an alternative approach i would really appreciate it! thanks =) please bare in mind that i am not very experienced, so if there are any pointless bits of code, or overcomplicated part, please let me know =)

ok note: i had to alter something, and now the program goes for 6 weeks playing the same matches as were played on week 1 each week..

Its all to do with what im trying to figure out.. so finding a way to achieve what i want should fix that too! thanks

heres my code to view

or you can download it here

PS it uses birch hansens java library cos thats whats on our course and thats here too...
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!