摘要: Leetcode 1796 寻找字符串中第二大的数字 1、两次遍历(省略) 2、一次遍历(max和second变量,代码省略) 3、范围0-9,桶排序(代码如下) class Solution { public: int secondHighest(string s) { int sortArr[1 阅读全文
posted @ 2022-12-03 22:46 夜初夏 阅读(19) 评论(0) 推荐(0)