Given a string, parse words beginning with space + # into an array.
Result:
myArray(0) = "big"
myArray(1) = "small"
myarray(2) = "\food"
Your code needs to be fully documented and will not be considered delivered unless it is fully documented.
## Deliverables
C# Class: Parse string with result in an array.
I would assume RegEx would be used.
Assume the following string as an example:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "[login to view URL]">
<html xmlns="[login to view URL]">
<head id="ctl00_ctl00_Head1"><meta http-equiv="pragma" content="no-cache" />
<title>
Do not include anything in here
</title></head>
<form>
<body>
The #big dog jumped over the #small dog because the #big dog w#anted the #\food '.
</form>
</body>
</html>
The string needs to be parsed with any word starting with # to be in an array.
Result:
myArray(0) = "big"
myArray(1) = "small"
myarray(2) = "\food"
Things to note:
-- Although "#big" dog is mentioned twice, it is only included in the array once.
-- The word "w#anted" is NOT included because the # symbol is in middle of the word.
-- No HTML characters such as ' are NOT to be included in the result array.
Public ReadOnly Properties
myArray
Number of items in array
Your code needs to be fully documented and will not be considered delivered unless it is fully documented.