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");
                }
            }
        }
    }
}
相关推荐
右耳朵猫AI2 分钟前
PHP技术周刊 2026年第20周
开发语言·php
方也_arkling14 分钟前
【Java-Day12】接口
java·开发语言
小小de风呀16 分钟前
de风——【从零开始学 C++】(十)vector的模拟实现
开发语言·c++
右耳朵猫AI22 分钟前
Rust技术周刊 2026年第20周
开发语言·后端·rust
kaico201831 分钟前
Python 在 Jenkins Pipeline 中的使用总结
开发语言·python·jenkins
流浪00132 分钟前
C++篇:深入理解 C++ 智能指针:从裸指针到 RAII 的蜕变
开发语言·c++
丘山望岳33 分钟前
二叉搜索双壁——map和set
开发语言·数据结构·c++
瑞雪兆丰年兮36 分钟前
[从0开始学Java|第十六、十七天]项目阶段(拼图小游戏)
java·开发语言
AI人工智能+电脑小能手36 分钟前
【大白话说Java面试题 第85题】【Mysql篇】第15题:MySQL 的事务中,幻读是怎么解决的?
java·开发语言·数据库·mysql·面试
yaoxin52112343 分钟前
423. Java 日期时间 API - DayOfWeek 和 Month 枚举
开发语言·python