Talk:Hackety Hacking Problem AreaofN SidedPolygon Methods

From OLPC
Revision as of 20:47, 16 October 2007 by Leejc (talk | contribs) (New page: A few points: * The sample output is wrong; the area of a square with side 2 is 4. * The problem statement does not make it clear why it is necessary to define a method. Defining a metho...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

A few points:

  • The sample output is wrong; the area of a square with side 2 is 4.
  • The problem statement does not make it clear why it is necessary to define a method. Defining a method only to call it immediately (and never again) unnecessarily complicates the solution.
  • You use the letter "l" as a parameter name; in most typefaces this letter is hard to distinguish from the number 1, which you also use in the function.

Joe 16:47, 16 October 2007 (EDT)