1、筛选数组arr中重复的元素,考虑时间复杂度。 时间复杂度为O(n) package writtenTest01; import java.util.ArrayList; import java.util.Arrays; import java.util.List; //手写代码:筛选数组arr中 ...
分类:
其他好文 时间:
2020-06-30 10:38:44
阅读次数:
53
1.简介 1.什么是RAID RAID ——Redundant Arrays of Inexpensive Disks,廉价冗余磁盘阵列,由数颗硬盘组成一个容错阵列系统。服务器或存储,硬盘都需要做RAID进行数据备份。 2.使用RAID的好处 1、提供硬盘串接,将所有的硬盘组成一个虚拟的大硬盘 2、 ...
分类:
其他好文 时间:
2020-06-29 00:26:05
阅读次数:
60
基数排序(Java) 博客说明 文章所涉及的资料来自互联网整理和个人总结,意在于个人学习和经验汇总,如有什么地方侵权,请联系本人删除,谢谢! 基数排序(桶排序)介绍 基数排序(radix sort)属于“分配式排序”(distribution sort),又称“桶子法”(bucket sort)或b ...
分类:
编程语言 时间:
2020-06-27 15:53:56
阅读次数:
54
Given a collection of numbers that might contain duplicates, return all possible unique permutations. Example: Input: [1,1,2] Output: [ [1,1,2], [1,2, ...
分类:
其他好文 时间:
2020-06-25 23:47:18
阅读次数:
92
写的很冗余,也没考虑类之间的关系,还能更简洁,更高效,仅做参考 有时间考虑做一个学生数据库 1 import java.util.Arrays; 2 import java.util.HashMap; 3 import java.util.Scanner; 4 5 public class Main ...
分类:
其他好文 时间:
2020-06-25 09:18:25
阅读次数:
65
You are given two arrays (without duplicates) nums1 and nums2 where nums1’s elements are subset of nums2. Find all the next greater numbers for nums1' ...
分类:
其他好文 时间:
2020-06-24 23:43:31
阅读次数:
50
package arrays /** * https://www.hackerrank.com/challenges/ctci-array-left-rotation/problem * * A left rotation operation on an array shifts each of t ...
分类:
其他好文 时间:
2020-06-24 16:08:32
阅读次数:
49
import java.util.Arrays; /** * @Class ThreeSumClosest * @Description 16. 最接近的三数之和 * 给定一个包括 n 个整数的数组 nums 和 一个目标值 target。找出 nums 中的三个整数, * 使得它们的和与 targ ...
分类:
其他好文 时间:
2020-06-24 12:20:26
阅读次数:
45
package cn.sunline.insd.cus.service.controller; import java.text.ParseException;import java.text.SimpleDateFormat;import java.util.Arrays;import java. ...
分类:
其他好文 时间:
2020-06-22 17:24:33
阅读次数:
85
题目如下: Given a rectangular cake with height h and width w, and two arrays of integers horizontalCuts and verticalCuts where horizontalCuts[i] is the di ...
分类:
其他好文 时间:
2020-06-22 15:31:47
阅读次数:
45