title: How to write a function that takes a list of strings as a parameter
body: <p>I want to create a function that takes a list of strings as a parameter, joins them together into a single string with each element separated by a comma, and returns the result. For example, if the array <code>[“asdf”, “jkl”, “zxc”]</code> is passed into the function, it will return a string <code>“asdf, jkl, zxc”</code>.</p>
  
  <p>In C#, my function signature look like this:</p>
  
  <pre><code>string MySolution(string[] inputStrings)
  
  {
    List&lt;string&gt; cities = new List&lt;string&gt;();
          cities.Add("New York");
          cities.Add("Mumbai");
          cities.Add("Berlin");
          cities.Add("Istanbul");
  
          string line = string.Join(",", cities.ToArray());
          Console.WriteLine(line);
  }
  </code></pre>
  
  <p>--I'm just having problems when it comes to having a user input where in a user will enter values, not the static as shown in the code. I will appreciate any suggestions or answers with regards to that. This also reserves as a test in the company that I'm applying for. </p>