Ram Prasad

Ram Prasad

  • 1.6k
  • 242
  • 3.5k

Combining array elements

Jun 30 2020 7:17 AM
I want to combine 2 consecutive elements of the even str array to create another string array with output as shown in example
 
For example if we have 6 elements in an array like
  1. string[] str = new string[] {"a""b""c""d""e""1"}   
it will combine in another string array strCombined to show output of {"ab", "cd", "e1"}
 
Please advise on how this can be done?

Brought to you by: JavaScript SDK for Bold BI dashboard and analytics embedding. Free trial.

Answers (5)