ldg7758521
幼苗
共回答了24个问题采纳率:83.3% 举报
using System;
using System.Collections.Generic;
using System.Text;
namespace ConsoleApplication2
{
class NamedWelcome
{
static void Main(string[] args)
{
Console.WriteLine("请输入一个句子");
string str = Console.ReadLine();
string[] split = str.Split(new char[] { ' ',',','.','!' });
foreach (string s in split)
{
if (s.Trim() != "")
Console.WriteLine("n"+s);
}
Console.ReadLine();
}
}
}
1年前
2