This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-module(erl_mysql). | |
%% 详细用法看测试代码 | |
-export([insert/2, | |
update/2, update/3, | |
delete/1, delete/2, delete/3, | |
select/1, select/2, select/3, select/4, select/5]). | |
%% TODO: maybe Values need support exp? | |
insert(Table, FVList) when is_list(FVList) -> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-module(erl_mysql_tests). | |
-include_lib("eunit/include/eunit.hrl"). | |
all_test_() -> | |
[insert(), | |
update(), | |
delete(), | |
select()]. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* 正确认识递归 | |
** 可终止性证明 | |
如果N传负数的话,就死循环了。 | |
sum(0) -> | |
0. | |
sum(N) when N > 0-> | |
N + sum(N-1). | |
这也是上次玩家经验为什么能吃掉16G内存的原因,递归没法终止。 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<head> | |
<meta charset="utf-8" /> | |
</head> | |
<body> | |
<form name="input" action="/test.php" method="post"> | |
I have a bike: | |
<input type="checkbox" name="vehicle1" value="Bike" /> | |
<br /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
print_r($_POST); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
%% 本数据结构大概目的,维护大规模数据选取小范围来随机,并定长维护,剔除老数据 | |
-module(lists_rand). | |
-export([new/0, cur/1, in/2]). | |
-define(SIZE, 10000). | |
-define(CHOOSE_COUNT, 5). | |
-record(list_rand,{ | |
max_size = ?SIZE, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//++ 合并两个pb结构++// | |
public static void mergeFromPb(object oldObj, object newObj, List<string> ignore_list = null){ | |
if(oldObj.Equals(newObj)) | |
return; | |
Type oldType = oldObj.GetType(); | |
Type newType = newObj.GetType(); | |
// if(oldType.Equals(newType) == false){ | |
// return; | |
// } | |
PropertyInfo[] newInfos = newType.GetProperties(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-module(lib_verifying_store_receipts). | |
-include("common.hrl"). | |
-include("define_http.hrl"). | |
-include("define_info_10.hrl"). | |
-export([send/1]). | |
-define(APP_VERIFY_RECEIPT_URL, "https://buy.itunes.apple.com/verifyReceipt"). | |
-define(APP_SANDBOX_VERIFY_RECEIPT_URL, "https://sandbox.itunes.apple.com/verifyReceipt"). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
王 | |
江 | |
周 | |
胡 | |
刘 | |
李 | |
吴 | |
毛 | |
温 | |
习 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Copyright 1999-2012 Gentoo Foundation | |
# Distributed under the terms of the GNU General Public License v2 | |
# $Header: /var/cvsroot/gentoo-x86/eclass/git-2.eclass,v 1.29 2012/04/03 10:32:09 pacho Exp $ | |
# @ECLASS: git-2.eclass | |
# @MAINTAINER: | |
# Michał Górny <mgorny@gentoo.org> | |
# Donnie Berkholz <dberkholz@gentoo.org> | |
# @BLURB: Eclass for fetching and unpacking git repositories. | |
# @DESCRIPTION: |
OlderNewer