码迷,mamicode.com
首页 >  
搜索关键字:php array 数组    ( 182180个结果)
[leetcode] Maximum Subarray
Find the contiguous subarray within an array (containing at least one number) which has the largest sum.
分类:其他好文   时间:2014-06-27 11:43:25    阅读次数:173
[leetcode] Jump Game
Given an array of non-negative integers, you are initially positioned at the first index of the array.
分类:其他好文   时间:2014-06-27 11:42:04    阅读次数:146
[leetcode] Anagrams
Given an array of strings, return all groups of strings that are anagrams.
分类:其他好文   时间:2014-06-27 11:34:57    阅读次数:641
《cocos2d-x游戏开发》—— lua学习总结(一)数组的使用
在lua中,数组是用table来实现的。1、数组的定义:self.itemArrays = {}; --作为数组来使用的表itemArrays2、 数组插入一条数据:local showItemSprite = CCSprite:create(); --创建一个精灵对象showItemSpri...
分类:其他好文   时间:2014-06-27 11:01:03    阅读次数:202
js中对数组的操作-------Day49
知其然,知其所以然,前路漫漫啊.......
分类:Web程序   时间:2014-06-27 10:26:28    阅读次数:131
二分搜索算法
二分搜索算法 题目:设 a [ 0 : n - 1 ] 是一个已排好序的数组。请改写二分搜索算法,使得当搜索元素 x 不在数组中时,返回小于 x 的最大元素的位置 i 和大于 x 的最小元素位置 j 。当搜索元素在数组中时, i 和j相同,均为 x 在数组中的位置。并对自己的程序进行复杂性分析。 import java.util.Arrays; import java.util.Scanner...
分类:其他好文   时间:2014-06-27 09:52:13    阅读次数:205
Codeforces 12D Ball 树状数组模拟3个元素的排序
题目链接:点击打开链接 #include #include #include #include #include #include #include #include #include #include #include using namespace std; #define N 500005 #define ll int ll n; ll c[N], maxn; inline ll...
分类:其他好文   时间:2014-06-27 09:06:04    阅读次数:183
UBUNTU安装PHP,即所谓得LAMP
Linux+Apache+Mysql/MariaDB+Perl/PHP/Python一组常用来搭建动态网站或者服务器的开源软件,本身都是各自独立的程序,但是因为常被放在一起使用,拥有了越来越高的兼容度,共同组成了一个强大的Web应用程序平台。随着开源潮流的蓬勃发展,开放源代码的LAMP已经与J2EE和.Net商业软件形成三足鼎立之势,并且该软件开发的项目在软件方面的投资成本较低,因此受到整个IT界...
分类:Web程序   时间:2014-06-27 08:35:53    阅读次数:268
First Missing Positive
题目 Given an unsorted integer array, find the first missing positive integer. For example, Given [1,2,0] return 3, and [3,4,-1,1] return 2. Your algorithm should run in O(n) time and u...
分类:其他好文   时间:2014-06-27 08:30:30    阅读次数:202
POJ 3624 Charm Bracelet 背包题解
最简单的背包问题了,本题应该除了背包就一个考点了:不能开二维数组。我没开过二维,不过看数据是不可以的。太大了。 做法有两种改进省内存DP: 1 所谓的滚动数组 2 逆向填表 很久没做背包DP,突然觉得这种背包问题很简单了。 下面给出两种解法: 1 calBag()是滚动数组 2 calBag2()是逆向填表 #pragma once #include #inclu...
分类:其他好文   时间:2014-06-27 08:09:43    阅读次数:165
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!