Home > Net >  C # programming
C # programming

Time:09-24

Array into a string x, please prepare the function, respectively, to delete the Spaces, punctuation, and where the subscript of the characters for an odd number of characters, the rest of the string to deposit into the output of the array x.

CodePudding user response:

I want to ask, the array into a string x is an array of strings, such as {" it ", "FSDFGDS", "ds FGSG}" in this way, or the string "AD s" into a single character (' a ', 'd', ', 's'},

CodePudding user response:

reference young programmer 1/f, small don's reply:
I want to ask, the array into a string x is an array of strings, such as {" it ", "FSDFGDS", "ds FGSG}" in this way, or the string "AD s" into a single character (' a ', 'd', ', 's'},

A string of 245! ,? H2.648 hd
Delete the subscript base Spaces, punctuation, and character

CodePudding user response:

, a quote from Daniel you teach the tuition to study, not to ask the teacher questions, come here to ask, that's not white made?

CodePudding user response:

references a sugar packets boy reply: 3/f
, a quote from Daniel you teach the tuition to study, not to ask the teacher questions, come here to ask, that's not white made?

task must be to get
The teacher is not to say

CodePudding user response:

 string STR="245! ,? H2.648 hd "; 
StringBuilder sb=new StringBuilder();
for (int i=0; I & lt; STR. Length; I++)
{
If ((I & amp; 1)!=1) continue;
Sb. Append (STR [I]);
}
  •  Tags:  
  • C#
  • Related