Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace capitalize
- {
- class Program
- {
- static void Main(string[] args)
- {
- while (true)
- {
- string[] input = Console.ReadLine()
- .Split(new char[] {' ',',','.','!','?','[',']','{','}','/','\\','@','#','$','%','^','&','*','(',')','-','_','|','<','>','+',':',';','~','`', }
- , StringSplitOptions.RemoveEmptyEntries).ToArray();
- if (input[0] == "end") { break; }
- for (int i = 0; i < input.Length; i++)
- {
- input[i] = input[i].ToLower();
- input[i] = char.ToUpper(input[i][0]) + input[i].Substring(1);
- }
- Console.WriteLine(string.Join(", ", input));
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment