码迷,mamicode.com
首页 >  
搜索关键字:sparse array    ( 29791个结果
LeetCode: Single Number
Given an array of integers, every element appears twice except for one. Find that single one. Note: Your algorithm should have a linear runtime comple...
分类:其他好文   时间:2014-05-23 07:22:48    阅读次数:241
php 验证上传图片尺寸
getimagesize 函数取得图像大小 (PHP 4, PHP 5)array getimagesize ( string filename [, array &imageinfo] ) //注意 ¥imageinfo在使用的时候不在需要前面的&。说明getimagesize() 函数将测定任何...
分类:Web程序   时间:2014-05-23 06:38:23    阅读次数:265
php 实现常用算法
//冒泡排序 从小到大对一组数排序function mp($array){ $count = count($array); if ($count $i; $k--) { if($array[$k] "; } return $...
分类:Web程序   时间:2014-05-23 05:39:26    阅读次数:284
【LeetCode】3Sum
Given an arraySofnintegers, are there elementsa,b,cinSsuch thata+b+c= 0? Find all unique triplets in the array which gives the sum of zero.Note:Elemen...
分类:其他好文   时间:2014-05-22 16:53:52    阅读次数:173
Single Number
Given an array of integers, every element appearstwiceexcept for one. Find that single one.Note:Your algorithm should have a linear runtime complexity...
分类:其他好文   时间:2014-05-22 16:31:03    阅读次数:194
CRC8算法DELPHI源码
unit Crc8;interfaceUsesClasses, Windows;Function Crc_8n(p : array of BYTE; len : BYTE) : Byte;implementationFunction Crc_8n(p : array of BYTE; len : B...
分类:其他好文   时间:2014-05-22 16:29:09    阅读次数:229
深度解析javascript中的浅复制和深复制
原文:深度解析javascript中的浅复制和深复制 在谈javascript的浅复制和深复制之前,我们有必要在来讨论下js的数据类型。我们都知道有Number,Boolean,String,Null,Undefined,Object五种类型。而Object又包含Function,Array和Obj...
分类:编程语言   时间:2014-05-22 15:13:54    阅读次数:334
41.把数组排成最小的数
Sort array to min value.
分类:其他好文   时间:2014-05-21 21:03:34    阅读次数:262
【leetcode】Remove Duplicates from Sorted Array
Given a sorted array, remove the duplicates in place such that each element appear onlyonceand return the new length.Do not allocate extra space for a...
分类:其他好文   时间:2014-05-21 20:00:51    阅读次数:296
Best Time to Buy and Sell Stock III
Say you have an array for which theithelement is the price of a given stock on dayi.Design an algorithm to find the maximum profit. You may complete a...
分类:其他好文   时间:2014-05-21 17:27:55    阅读次数:252
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!