http://entrian.com/goto/# Example 1: Breaking out from a deeply nested loop:from goto import goto, labelfor i in range(1, 10): for j in range(1, 20...
分类:
编程语言 时间:
2014-09-18 18:34:14
阅读次数:
235
前言 RMQ: 数组 a0, a1, a2,..., an-1, 中求随意区间 a[i+1], a[i+2], ..., a[i+k] 的最小值 LCA: 求二叉树中两个节点的最低公共祖先 本文将证明这两个问题能够相互归约为还有一个问题。证明 先通过一个简单的样例来说明问题。见下图: 求 [7...
分类:
其他好文 时间:
2014-09-18 16:24:44
阅读次数:
144
生成excel的时候有时候需要设置单元格的一些属性,可以参考一下: 1 range.NumberFormatLocal = "@"; //设置单元格格式为文本 2 ange.get_Range("B1","B"+dataGridView2.RowCount+1).NumberFormat =...
分类:
其他好文 时间:
2014-09-18 09:46:33
阅读次数:
272
使用python的人都知道range()函数很方便,今天再用到他的时候发现了很多以前看到过但是忘记的细节。这里记录一下range(),复习下list的slide,最后分析一个好玩儿的冒泡程序。这里记录一下:>>> range(1,5) #代表从1到5(不包含5) [1, 2, 3, 4] >>> r...
分类:
编程语言 时间:
2014-09-17 21:43:02
阅读次数:
311
后缀数组+RMQ+二分
后缀数组二分确定第K不同子串的位置 , 二分LCP确定可选的区间范围 , RMQ求范围内最小的sa
Boring String Problem
Time Limit: 6000/3000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)
Total Submission(s): 661...
分类:
其他好文 时间:
2014-09-17 16:53:22
阅读次数:
256
11.1背景:模拟优化参数optimizer_switch选项mrr(Multi_RangeRead)对查询优化的影响11.2建表语句mysql>showcreatetableorder_line\G;***************************1.row***************************Table:order_lineCreateTable:CREATETABLE`order_line`(`ol_o_id`int(11)N..
分类:
其他好文 时间:
2014-09-17 15:33:13
阅读次数:
338
Given a sorted array of integers, find the starting and ending position of a given target value.Your algorithm's runtime complexity must be in the ord...
分类:
其他好文 时间:
2014-09-17 13:31:02
阅读次数:
144
题目: https://oj.leetcode.com/problems/integer-to-roman/Given an integer, convert it to a roman numeral.Input is guaranteed to be within the range from ...
分类:
编程语言 时间:
2014-09-17 06:46:11
阅读次数:
285
题目:https://oj.leetcode.com/problems/roman-to-integer/Given a roman numeral, convert it to an integer.Input is guaranteed to be within the range from 1...
分类:
编程语言 时间:
2014-09-17 06:45:51
阅读次数:
269
一个php生成16位随机数的代码,php生成随机数的二种方法。方法1<?php$a = mt_rand(10000000,99999999);$b = mt_rand(10000000,99999999);echo $a.$b;方法2:<?php$a = range(0,9);for($i=0;$i...
分类:
Web程序 时间:
2014-09-16 20:22:31
阅读次数:
299