04 2021 档案

LeetCode第235场周赛题解
摘要:LeetCode第235场周赛题解 截断句子 按照题目要求模拟即可,把单词读入到vector中,然后按要求拼接即可 class Solution { public: string truncateSentence(string s, int k) { vector<string> a; string 阅读全文

posted @ 2021-04-04 13:37 翔鸽 阅读(83) 评论(0) 推荐(0)

LeetCode第49场双周赛题解
摘要:LeetCode第49场双周赛题解 判断国际象棋棋盘中一个格子的颜色 如果是a,c,e,g列,行数是偶数即为白格子,如果是b,d,f,h列,行数为奇数即为白格子 class Solution { public: bool squareIsWhite(string coordinates) { cha 阅读全文

posted @ 2021-04-04 09:50 翔鸽 阅读(89) 评论(0) 推荐(0)