MD5-HY
MD5-HY
全部文章
分类
题解(35)
归档
标签
去牛客网
登录
/
注册
MD5-HY的博客
全部文章
(共33篇)
题解 | #和为S的两个数字#
import java.util.ArrayList; public class Solution { public ArrayList<Integer> FindNumbersWithSum(int [] array,int sum) { ArrayList&l...
2021-06-30
0
307
题解 | #滑动窗口的最大值#
import java.util.*; public class Solution { public ArrayList<Integer> maxInWindows(int [] num, int size) { ArrayList<Integer> ...
2021-06-30
0
344
题解 | #字符流中第一个不重复的字符#
import java.util.*; public class Solution { private int[] arr = new int[128]; private int index = 0; //Insert one char from stringstream ...
2021-06-30
0
311
题解 | #数据流中的中位数#
import java.util.*; public class Solution { List<Integer> list = new ArrayList<Integer>(); public void Insert(Integer num) { ...
2021-06-30
0
314
题解 | #最小的 K 个数#
import java.util.*; public class Solution { public ArrayList<Integer> GetLeastNumbers_Solution(int [] input, int k) { ArrayList<...
2021-06-30
0
276
题解 | #栈的压入、弹出序列#
import java.util.ArrayList; import java.util.Stack; public class Solution { public boolean IsPopOrder(int [] pushA,int [] popA) { int n =...
2021-06-30
0
298
题解 | #包含 min 函数的栈#
import java.util.Stack; public class Solution { Stack<Integer> stack1 = new Stack<Integer>(); Stack<Integer> stack2 = new S...
2021-06-30
0
328
题解 | #用两个栈来实现队列#
import java.util.Stack; public class Solution { Stack<Integer> stack1 = new Stack<Integer>(); Stack<Integer> stack2 = new S...
2021-06-30
0
285
题解 | #第一个只出现一次的字符#
public class Solution { public int FirstNotRepeatingChar(String str) { int[] cns = new int[128]; for(int i=0;i<str.length();i++...
2021-06-30
0
298
题解 | #顺时针打印矩阵#
import java.util.ArrayList; public class Solution { public ArrayList<Integer> printMatrix(int [][] matrix) { ArrayList<Integer>...
2021-06-30
0
456
首页
上一页
1
2
3
4
下一页
末页