Title case a sentence (uppercase in the first letter of the word)
Requirements
Make sure that the first letter of each word in the string is capitalized, and the remainder is lowercase.
Connectors like ' the ' and ' of ' are the
Use the JS operation to ensure that the first letter of each word of the string is capitalized and the remainder lowercase.function titlecase (str) { var arr = Str.split (""); var newarray = []; for (var i = 0; i ) { var newstr =
Solution Ideas
Convert a string to lowercase
To split a string into a string array
Loop array capitalize each word first letter
Converts all elements of an array into a string
The first of these methodsfunction Titlecase
Website construction and Network marketing is definitely a success in the details of the work, in search engines constantly strengthen the user experience first now, perhaps just a small detail of negligence will let all efforts to naught. There are
Title: Enter an English sentence, flipping the order of the words in the sentence, but the order of the characters within the word is unchanged. Words are separated by spaces in sentences. For simplicity, punctuation is treated like ordinary letters.
Time limit: 1 seconds space limit: 32768K heat index: 23758 algorithmic Knowledge video explanation
Title DescriptionGiven a sentence (containing only letters and spaces), the word position in the sentence is reversed, the word is separated by a
Although many sites began to pay attention to, but still have a lot of sites do not understand SEO, especially the enterprise station, especially in the Site page title on the most obvious settings, in this regard many of the government web site is
What makes you really want, think without hesitation, open an email? E-mail Thousands, any enterprise that carries out mail marketing may be your competitor, then the question comes, how to kill the thousand objects in seconds? The pressure is great,
The website's title, keywords, and descriptions are invisible to many webmasters. I think Baidu has not paid much attention to this part, so any title can be seen! The title of a website can contain up to one thousand words, and can also be seen
Obtain the height of the status bar:
Rect frame = new rect (); (moveviewdemo) context ). getwindow (). getdecorview (). getwindowvisibledisplayframe (FRAME); // all areas except the display area that comes with the system are obtained here.
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.