- using ConsoleApp1;
- using System;//程式庫呼叫
- using System.ComponentModel.DataAnnotations;
- using System.Linq.Expressions;
- using ABC.qq;
- class Program//負責一部分工作的人
- {
- static string weeks="Mon Tus Wed Thr Fri Sat Sun";
- static void main()
- {
- try
- {
- string[] week=weeks.Split(' ');//以空格切割並一一文放到week陣列
- int x=Convert.ToInt32(Console.ReadLine());
- Console.WriteLine(week[x].ToString());
- }catch
- {
- Console.WriteLine("error");
- }
- }
-
- }
複製代碼 |