标签:unsigned 图片 nbsp 简单 c代码 namespace lan sda src
简单模拟 没啥说的
AC代码:
1 #include<bits/stdc++.h> 2 using namespace std; 3 typedef long long ll; 4 typedef unsigned long long ull; 5 6 int t; 7 int start, dis; 8 string s; 9 string day[5] = {"Monday", "Tuesday", "Wednesday", "Thursday", "Friday"}; 10 11 int main(){ 12 int y1, m1, d1, y2, m2, d2; 13 cin>>t; 14 while (t--){ 15 start = 0; 16 cin>>y1>>m1>>d1; 17 cin>>s; 18 cin>>y2>>m2>>d2; 19 dis = d2 - d1 + 30; 20 for (int i = 0; i < 5; i++) 21 if (s == day[i]) start = i; 22 cout<<day[(start + dis) % 5]<<endl; 23 } 24 return 0; 25 }
标签:unsigned 图片 nbsp 简单 c代码 namespace lan sda src
原文地址:https://www.cnblogs.com/Misuchii/p/10896252.html