码迷,mamicode.com
首页 >  
搜索关键字:end    ( 30778个结果
[leetcode]Remove Nth Node From End of List
Remove Nth Node From End of ListGiven a linked list, remove thenthnode from the end of list and return its head.For example, Given linked list: 1->2.....
分类:其他好文   时间:2014-07-22 22:53:35    阅读次数:220
atitit.提升开发效率---MDA 软件开发方式的革命(5)----列表查询建模
atitit.提升开发效率---MDA 软件开发方式的革命(5)----列表查询建模   1. 配置条件字段@Conditional 1 2. 配置条件字段显示类型为range----@Conditional(displayType = displayType.rang, rangStart = rang.start, rangEnd = rang.end,op=op.range) 1 3...
分类:其他好文   时间:2014-07-20 00:17:55    阅读次数:215
splice slice
array的方法中,有这么两个方法, 很久之前接触flex的时候就知道了。 可是总是记不太清。splice() 方法向/从数组中添加/删除项目,然后返回被删除的项目slice() 方法可从已有的数组中返回选定的元素。 语法 arrayObject.slice(start,end) 参数描述 star...
分类:其他好文   时间:2014-07-19 22:39:50    阅读次数:264
sort函数使用的基本知识
STL中就自带了排序函数sortsort 对给定区间所有元素进行排序 要使用此函数只需用#include sort即可使用,语法描述为:sort(begin,end),表示一个范围,例子:#include int main(){ int a[20]={2,4,1,23,5,76,0,43,24,6....
分类:其他好文   时间:2014-07-19 18:36:51    阅读次数:217
HDU 1231
求最大连续子序列一开始想到的一种O(n^2)的算法,应该会超时运用动态规划的思想,想出了下面的方法#include using namespace std;struct DP{ int sum,sta,end; void init(int su,int st,int en){ sum=su; sta...
分类:其他好文   时间:2014-07-19 18:04:36    阅读次数:230
LeetCode Rotate Image
class Solution {public: void rotate(vector > &matrix) { int n = matrix.size(); int end = n / 2; for (int i=0; i<end; i++) { ...
分类:其他好文   时间:2014-07-19 11:19:11    阅读次数:162
USACO Section 2.1 Sorting a Three-Valued Sequence
/* ID: lucien23 PROG: sort3 LANG: C++ */ #include #include #include #include using namespace std; void exchange(int nums[], int begin, int end, int N, int x); int sum = 0; int main() { ifstream ...
分类:其他好文   时间:2014-07-19 02:12:25    阅读次数:176
LeetCode Remove Nth Node From End of List
class Solution {public: ListNode *removeNthFromEnd(ListNode *head, int n) { if (head == NULL) return NULL; ListNode* pre = NULL; ...
分类:其他好文   时间:2014-07-18 18:24:55    阅读次数:209
ruby on rails错误undefined method `title' for nil:NilClass
首先搞清楚这句话,在 Ruby 中,方法分为 public、private 和 protected 三种,只有 public 方法才能作为控制器的动作。 我的出错的代码如下: controlle class ArticlesController < ApplicationController def new end def create params.permit...
分类:其他好文   时间:2014-07-18 18:14:43    阅读次数:295
GCD(1)
```objc#import "ViewController.h"int threadNumber = 0;int newThingNumber = 0;@interface ViewController ()@end@implementation ViewController- (void)vie...
分类:其他好文   时间:2014-07-18 14:23:25    阅读次数:229
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!