Tags:
create new tag
view all tags

Help on isValid

  • Use a constant for the required length of a string
  • if the string sent the method is not the right length, return false
  • Assume the string is valid
  • for each character in the string
    • if the character is not a valid color
      • know that the string is no longer valid (and will NOT become valid again)
  • return if the string was determined valid or not
Topic revision: r1 - 2023-01-31 - cathybareiss
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2026 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback