算法
文章平均质量分 72
小宇0000
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
稠密(dense)并且唯一(unique)的随机(random)数生成
本文是针对Jim Gray Sigmod94年的论文《Quickly GeneratingBillion-Record Synthetic Databases》第五章节的翻译和一点见解。主要介绍稠密(dense)并且唯一(unique)的随机(random)数生成算法。原创 2015-07-15 20:16:53 · 1729 阅读 · 0 评论 -
遗传算法解01背包问题(Java)
遗传算法解01背包问题,并给出了完整可运行的java代码原创 2015-09-12 16:26:51 · 6341 阅读 · 3 评论 -
leecode algo1: Two Sum (Java)
leecode algo1: Two Sum题目:Given an array of integers, find two numbers such that they add up to a specific target number.The function twoSum should return indices of the two numbers such th原创 2015-10-08 20:38:06 · 494 阅读 · 0 评论 -
leecode algo3: Longest Substring Without Repeating Characters (Java)
leetcode algo3:Longest Substring Without Repeating Characters题目:Given a string, find the length of the longest substring without repeating characters. For example, the longest substring without re原创 2015-10-08 20:27:17 · 530 阅读 · 0 评论 -
寻找字符串的最长不重复子串,计算复杂度O(n),两种实现
问题:给定一个字符串,找出这个字符串中最长的不重复子串。计算负责度:O(n)原创 2015-07-17 11:57:59 · 10829 阅读 · 0 评论 -
leecode algo4: Median of Two Sorted Arrays (Java)
leetcode algo4:Median of Two Sorted Arrays题目:There are two sorted arrays nums1 and nums2 of size m and n respectively. Find the median of the two sorted arrays. The overall run time complexity s原创 2015-10-08 20:04:14 · 551 阅读 · 0 评论 -
leecode algo2: Add Two Numbers (Java)
leecode algo1: Add Two Numbers题目:You are given two linked lists representing two non-negative numbers. The digits are stored in reverse order and each of their nodes contain a single digit. Add原创 2015-10-08 20:32:52 · 531 阅读 · 0 评论 -
Java求n以内的所有质数
质数(prime number)又称素数,有无限个。一个大于1的自然数,除了1和它本身外,不能被其他自然数整除,换句话说就是该数除了1和它本身以外不再有其他的因数;否则称为合数。方法1:根据质数的定义求解;方法2:对方法1作进一步优化,仅需判断到该数的平方根;方法3:基于规律“除了2,所有的质数都是奇数;如果一个数不能被它之前的质数整除,那么这个数是质数”进一步优化程序。示例程序如原创 2015-11-03 21:59:26 · 8953 阅读 · 1 评论 -
Java AES256加密解密实现
Java AES256加密解密实现原创 2015-09-12 16:38:05 · 41799 阅读 · 8 评论 -
算法复杂度分析中的符号(Θ、Ο、ο、Ω、ω)简介
算法复杂度分析中的符号(Θ、Ο、ο、Ω、ω)简介原创 2015-07-17 16:42:49 · 62707 阅读 · 5 评论 -
计数排序的理解与实现
计数排序是一种非基于比较的排序算法,其空间复杂度和时间复杂度均为O(n+k)原创 2015-07-16 16:03:43 · 10935 阅读 · 3 评论
分享