Further info on the challenge -- gc >X-Sender: [EMAIL PROTECTED] >Date: Sun, 18 Nov 2001 12:42:33 -0500 >To: "CHALLENGE-A" <[EMAIL PROTECTED]> >From: Bob Boonstra <[EMAIL PROTECTED]> >Subject: Q&A#1 for December Conferences Challenge >Sender: <[EMAIL PROTECTED]> >List-Subscribe: <mailto:[EMAIL PROTECTED]> >List-Digest: <mailto:[EMAIL PROTECTED]> >List-Unsubscribe: <mailto:[EMAIL PROTECTED]> > >Q1: Points for dual-parent conferences > >> > Johnny Smith, Donald Smith, Marilyn Waters-Smith >>> Johnny Smith, Rene Descartes, 9 >>Does this imply that if neither parent has met Rene Descartes, I obtain 2*9=18 >penalty points > >A1: No, only 9. The requirement is that at least one of Jonny's parents meet with >the teacher. > >Q2: Parents with multiple children > >>May the same parent have several children in school e.g >>> Johnny Smith, Donald Smith, Marilyn Waters-Smith >> > Laura Smith, Donald Smith, Marilyn Monroe > >A2: Yes, the same parent might have more than one child in school. And, although I >hadn't thought of it before, two children of one parent might have different second >parents, as in your example. > >Q3: Points for multiple children with the same teacher > >>If the same parent have several children in school e.g >>> Johnny Smith, Donald Smith, Marilyn Waters-Smith >>> Laura Smith, Donald Smith, Marilyn Monroe >>And they have the following desire for a conference >> >Johnny Smith, Rene Descartes, 9 >> >Laura Smith, Rene Descartes, 5 >>Does a conference between Donald Smith ond Rene Descartes clear all 14 points? > >A3a: Yes. One conference between a parent and a teacher can satisfy requests on >behalf of more than one child of that parent. > >>Does a conference between Donald Smith, Marilyn Waters-Smith ond Rene Descartes >clear 23 points? > >A3b: No, there are only 14 points involved in these two conferences, no matter how >many parents attend the conferences. > >Q4: Number of test cases > >> >The final data set, in a file named schedulesNN.txt, identifies which >>>parents are available at which times. The first line in this file >>>contains the number N of conference periods available for scheduling. >>>All teachers can be available for any or all of the periods from >>>1..N. >> >>... and this assumes that... >> >>N < 10 >> >>right (just as in the files' names definition where a 'N' means only one >>numeral byte)? > >A4: Actually, NN<100. The file name contains two digits, so the problem should say >"the number NN of conference periods ..." > >Q5: Should timing include file I/O? > >> >Finally, your solution needs to produce a log file (log.txt) that >>>contains, for each test case, the execution time in milliseconds that >>>your solution required to process the test case. >> >>I guess that this log file being produced in "test code fashion", we >>would start measuring after the files are loaded into memory and would >>stop right after the actual solving function returns, thus stopping right >>before the returned data is written into the output ("conferencesNN.txt") >>files? >> >>i.e. file i/o would not be counted in the execution time? > >A5: A reasonable interpretation, but actually, test time should measure from entry to >exit of your program. If there were a test driver, it would measure from when your >code is called to when it returns. In this case, your code does the I/O, so all >should be included. (Obviously you cannot time writing the timing measurement.) > >Q6: Are parent names unique? > >>Your problem statement doesn't preclude the possibility of multiple >>parents having the same name. Parents could have multiple children in the >>school and different parents could have the same name. Can we assume that >>all parent names will be unique? > >A6: Good point. Yes, you can assume parent names will be unique. > >Q7: May I use Perl? > >>Any problems if I code an entry in Perl? I'll do this on OS X which includes >>a perl distribution so you should already have it. > >A7: No problem with Perl. If you prefer to use OS 9.x, I also have MacPerl. Suggest >you send me a test solution and build instructions at some point so that I can verify >that I can successfully build the solution. > >-- >-- Programmer's Challenge -- Bob Boonstra > [EMAIL PROTECTED] [EMAIL PROTECTED] > <http://www.mactech.com/> <http://home.earthlink.net/~bobboonstra> >
Archives: http://www.mail-archive.com/[email protected]/ Info: http://www.xworlds.com/metacard/mailinglist.htm Please send bug reports to <[EMAIL PROTECTED]>, not this list.
