tag:blogger.com,1999:blog-8338396833705157791.post1329647670452161232..comments2023-06-01T08:01:28.718+01:00Comments on My Code Here: Regex TennisJohn M Kerrhttp://www.blogger.com/profile/09707247617873542958noreply@blogger.comBlogger2125tag:blogger.com,1999:blog-8338396833705157791.post-16276448729120493572012-06-23T17:13:28.312+01:002012-06-23T17:13:28.312+01:00I can remember trying to solve this problem in fir...I can remember trying to solve this problem in first year of Comp. Sci :) brought back a lot of memories :)Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-8338396833705157791.post-7824293866302526152011-02-21T12:25:43.707+00:002011-02-21T12:25:43.707+00:00The number of n-point games, g(n), is:
g(n) = 2 *...The number of n-point games, g(n), is:<br /><br />g(n) = 2 * C(n-1, n-4), 4 <= n <= 6;<br />g(n) = 5 * 2^(n/2 - 1), 6 <= n, n even;<br />g(n) = 0 otherwise,<br /><br />where C(n, k) is the binomial coefficient "n choose k", and "^" denotes exponentiation.<br /><br />n : g(n)<br />=====<br />4 : 2<br />5 : 8<br />6 : 20<br />7 : 0<br />8 : 40<br />9 : 0<br />10 : 80<br />11 : 0<br />12 : 160<br />13 : 0<br />14 : 320<br /><br />Added as a comment because the Blogger WYSIWYG editor destroys the format of my indented code upon every save, and in just such a surprising way as to make Very Challenging the task of pre-stressing it, so that it collapses into the desired state.John M Kerrhttps://www.blogger.com/profile/09707247617873542958noreply@blogger.com