QL-1) TDD lab.

You are going to develop a small piece of code that accepts a comma-delimited list of tags (words/tokens - characters, numbers, some symbols like $£%& but not a comma) and must return an array of tags. The preceding and proceeding commas should be removed, white spaces preceding the first tag must be removed, white spaces succeeding the last tag must be removed, and contiguous series of words separated with spaces and ended with a comma should be treated as a single tag

Examples of the rules are as follows

  • "csharp" must return ["csharp"]

  • "csharp, python" must return ["csharp", "python"]

  • "java, C#, python" must return ["java", “C#”, "python"]

  • " csharp" must return ["csharp"]

  • ",csharp" must return ["csharp"]

  • "csharp," must return ["csharp"]

  • "C# byte code, python" must return ["C# byte code", "python"]