Dig for a less common trim overload

Source: Internet
Author: User

I don't think the developer said I don't know, but there's an overload inside that doesn't know how many developers know!

As you can see, I can remove the specified character before and after the string, as long as I apply in char[], instead of just removing the space, why should I mention it this time because the former

A few days when using ASP docking. NET, there is a Join method in ASP, but it is not like C # String.Join (",") method can remove the tail ",", such as

Array {* * *}, after join in ASP will become "a", and C # will become "" ", this time when the ASP passed, in C # can use trim to remove

Tail of the "," out.

var"1,2,3,";            var r = s.Trim(newchar‘,‘ });            Console.WriteLine(r);            Console.Read();

All right, that's all, no technical content, the point is digging a dig, maybe useful to you ~

Dig for a less common trim overload

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.