- 博客(1)
- 收藏
- 关注
原创 一道未解决的称不上算法的算法题
一道未解决的称不上算法的算法题 题目: 翻译翻译: 题目的解决思路是,在一组数组中,向左去寻找第一个比A[i]大的元素,并将找到的数组元素下标记录在一个新的数组中,所以以下是暴力解,时间复杂度O(n2) public int[] communicate(int[] A){ int length = A.length; int[] res = new int[length]; for(int i = 0;i < length;i++){ for(int j = i-1;j > -1
2022-03-19 01:11:57 406
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人