标签:class return int res back esb IV tor cto
1 static int wing=[]() 2 { 3 std::ios::sync_with_stdio(false); 4 cin.tie(NULL); 5 return 0; 6 }(); 7 8 class Solution 9 { 10 public: 11 vector<string> fizzBuzz(int n) 12 { 13 vector<string> vs{"Fizz","Buzz","FizzBuzz"}; 14 vector<string> res(n); 15 for(int i=1;i<=n;i++) 16 { 17 if(i%15==0) 18 res[i-1]=vs[2]; 19 else if(i%3==0) 20 res[i-1]=vs[0]; 21 else if(i%5==0) 22 res[i-1]=vs[1]; 23 else 24 res[i-1]=to_string(i); 25 } 26 vector<string> &resback=res; 27 return resback; 28 } 29 };
FB游戏,问题不大
标签:class return int res back esb IV tor cto
原文地址:https://www.cnblogs.com/zhuangbijingdeboke/p/9095334.html