L1-059 敲笨钟 c#

csharp 复制代码
using System.Collections;
using System.Runtime.InteropServices;
using System.Text.RegularExpressions;
using System;
namespace class20240724
{
    internal class Program
    {
        static void Main(string[] args)
        {
            int count = int.Parse(Console.ReadLine());
            for(int i = 0; i < count; i++)
            {
                string line = Console.ReadLine();
                string[] arr = line.Split(',');
                if (arr[0].EndsWith("ong") && arr[1].EndsWith("ong."))
                {
                    string[] arr2 = arr[1].Split();
                    arr2[arr2.Length - 1] = "zhong.";
                    arr2[arr2.Length - 2] = "ben";
                    arr2[arr2.Length - 3] = "qiao";
                    string merge = string.Join(" ", arr2);
                    Console.WriteLine(arr[0]+","+merge);
                }
                else
                {
                    Console.WriteLine("Skipped");
                }
            }
        }
    }
}
相关推荐
BatyTao3 小时前
QT下载并安装
开发语言·qt
赵钰老师3 小时前
MATLAB在生态环境数据处理与分析中的应用
开发语言·matlab
杰建云1673 小时前
小程序从零搭建全流程实战指南
开发语言·小程序·php
李少兄3 小时前
解决 java.net.ConnectException: Connection refused 报错
java·开发语言·.net
gumichef3 小时前
栈和队列(1)
开发语言·数据结构
2601_953465613 小时前
纯前端高性能!m3u8live.cn 重新定义 M3U8 在线播放与调试体验
开发语言·前端·javascript·m3u8
步步为营DotNet3 小时前
NET 11 中 C# 14 新特性在云原生微服务架构的深度实践
云原生·架构·c#
云天AI实战派3 小时前
Python 智能体实战:从 0 搭建模块化 Agent 路由系统,落地小龙虾门店运营助手
开发语言·人工智能·python
tumu_C3 小时前
C++模板:Ret(Arg...)的相关
开发语言·c++·算法
小白学大数据3 小时前
新闻爬虫开发实战:Python 搞定新闻网站关键词文章抓取
开发语言·爬虫·python·自动化