由买买提看人间百态

topics

全部话题 - 话题: assert
首页 上页 1 2 3 4 5 6 7 8 9 10 下页 末页 (共10页)
M******e
发帖数: 1193
1
来自主题: USANews版 - 这个时候poll已经根本没用了
Benghazi/Libya
Hillary Clinton Discussed Libya’s Struggles After Gaddafi’s Fall. “In
Libya, they had one of the best elections in the whole region after the fall
of Gaddafi, but they've not been able to assert control over the security
of their nation in any way yet. So they have a lot of the right impulses and
desires, but don't know how to move the levers of authority to provide
security for citizens, business interests and the like.” [Hamilton College
Speech, 10/4/13]
Clinton Said Libya Was A... 阅读全帖
M******e
发帖数: 1193
2
来自主题: USANews版 - 这个时候poll已经根本没用了
Benghazi/Libya
Hillary Clinton Discussed Libya’s Struggles After Gaddafi’s Fall. “In
Libya, they had one of the best elections in the whole region after the fall
of Gaddafi, but they've not been able to assert control over the security
of their nation in any way yet. So they have a lot of the right impulses and
desires, but don't know how to move the levers of authority to provide
security for citizens, business interests and the like.” [Hamilton College
Speech, 10/4/13]
Clinton Said Libya Was A... 阅读全帖
l******h
发帖数: 2
3
Highly reputational company with very competitive compensation for all
positions.
Please send in your resume and position/positions you like to apply to my
email address below.
h*******[email protected]
All resumes will be deliver to hiring manager directly. Act fast!
Thanks!
Silicon Engineering Group
Sr. Physical Design Timing Engineer
Timing (STA) Manager
Senior Physical Design Engineer
CAD Manager - Front-End Design and Verification
Sr. CAD Engineer - Place & Route / Physical Design Engineer
Sr. CA... 阅读全帖
i**********e
发帖数: 1145
4
来自主题: JobHunting版 - 求一题的完美简洁解答
贴一贴我的代码吧,抛砖引玉.
代码已经改了好几遍,尽量简洁,但是有一些部分还是非常 tricky 的.
代码经过严格的测试.
如果你要测试数据,可以站内联系我.
另外要提到的是:
我想这题难度系数还是满大的,网上的解法不一定对,例如这个就有好几个 bug:
http://geeksforgeeks.org/?p=2105
第一,没有得到平均和(他的直接除以二然后 truncate )
第二,测试了有好几个 case 没通过
很多网上的答案都只能够处理 m == n 的情况,看来 m != n 的情况复杂很多,其实不
是. 掌握思路要点后一点也不难,就是要确保这个 invariant 得到满足:
-- 每次从数组 A 和数组 B 去掉的元素个数必须相等.
掌握了以上的每次去除元素的思路,递归就很直接可以写出来,这只是解这道题最简单
的部分,更难的还有以下非常 tricky 的要点:
1)怎么知道递归的终止条件? 应该很容易想到当其中一个数组个数为 1 的时候,就
必须个别处理,不然就会死循环. 而为什么其中数组个数为 2 的时候也必须个别处理
就不是那么明显了.
2)当个别处理 spec... 阅读全帖
f**l
发帖数: 44
5
来自主题: JobHunting版 - 贡献一道G家的面试题
Related test cases:
@Test
public void testProcessString() {
String s1 = "CAABD";
String target1 = "CBBD";
Assert.assertEquals(target1, StringAndArray.processString(s1.
toCharArray(), s1.length()));
String s2 = "ACAABDB";
String target2 = "CBBDBB";
Assert.assertEquals(target2, StringAndArray.processString(s2.
toCharArray(), s2.length()));
String s3 = "BACAABDBA";
String target3 = "BBCBBDBB";
Assert.assertEquals(target3, S... 阅读全帖
o***d
发帖数: 313
6
来自主题: JobHunting版 - leetcode:这题 int sqrt(int)??!!为啥用int
//my code which fails test cases of leetcode
double sqar(double a)
{
if (a < 0)
throw -1;
double x1, x2, xt, at, E;
E = 0.00001;

if (a >= 1)
{
x1 = 0.99;
x2 = a+0.01;
assert(x1*x1-a < 0);
assert(x2*x2-a > 0);
}
else
{
//--original wrong codec
//x1 = 1.01;
//x2 = (a+1)/2;
x1 = a/2;
x2 = 1.01;
//--oringal wrong code, x1 could be 0
//assert(x1*x1-a < 0);
assert(x1*x1-a < E);
... 阅读全帖
m*****k
发帖数: 731
7
来自主题: JobHunting版 - Google onsite 题目求助
counter用不着吧,sliding window idea,
public static int getLongestSubStringWith2Chars(String s) {
if(s==null || s.isEmpty()){
return 0;
}
int c1Idx = 0;
int c2Idx = 0;
int c3Idx = 0;
int l = 0;
for (int i = 1; i < s.length(); i++) {
if (s.charAt(i) != s.charAt(c2Idx)) {
c3Idx = i;
int temp = c3Idx - c1Idx;
if (temp > l) {
l = temp;
Sys... 阅读全帖
n****5
发帖数: 81
8
来自主题: JobHunting版 - fb电面面经
用 C 写了一下,用的递归来处理商和余数。用的unsigned int所以假定输入小于1百万
X1百万
#include
#include
const char* tens[] = {"Twenty", "Thirty", "Forty", "Fifty", "Sixty", "
Seventy", "Eighty", "Ninety"};
const char* lt20[] = {"Zero", "One", "Two", "Three", "Four", "Five", "Six",
"Seven", "Eight", "Nine", "Ten",
"Eleven", "Twelve", "Thirteen", "Fourteen", "Fifteen", "
Sixteen", "Seventeen", "Eighteen", "Nineteen"};
void num2str(unsigned int num)
{
if (num == 0)
return;
el... 阅读全帖
l******h
发帖数: 2
9
Highly reputational company with very competitive compensation for all
positions.
Please send in your resume and position/positions you like to apply to my
email address below.
h*******[email protected]
All resumes will be deliver to hiring manager directly. Act fast!
Thanks!
Silicon Engineering Group
Sr. Physical Design Timing Engineer
Timing (STA) Manager
Senior Physical Design Engineer
CAD Manager - Front-End Design and Verification
Sr. CAD Engineer - Place & Route / Physical Design Engineer
Sr. CA... 阅读全帖
o*******u
发帖数: 242
10
来自主题: Immigration版 - 学习AAO的EB1B administrative decision心得
E. Contribution
5.1 何谓贡献?
• As noted by counsel on appeal, the plain language of the
regulation at 8 C.F.R. 5 204.5(i)(3)(i)(E) does not require that the
beneficiary's contributions themselves be internationally recognized as
outstanding. That said, the plain language of the regulation does not
simply
require original research, but an original "research contribution."
• Obviously, the petitioner cannot satisfy this criterion simply by
listing the beneficiary's past pr... 阅读全帖
B**********r
发帖数: 812
11
来自主题: Immigration版 - 被 NOID了,请大家帮忙想想办法
参看知名律师网上的
your response should prove your evidence is at least 51% believable to IO
http://www.niwus.com/art0022.html
移民申请的举证标准及RFE问题
按照移民局的工作程序,如果移民官在审理案件时发现某些主要证据缺失,可以要求申
请人补充证据
(RFE)。如果主要证据齐全,移民官则需要批准申请,而不必再要求申请人补充一些
无关紧要的材料。
不过,在实际操作中,有些移民官并不完全遵守工作程序,在申请人已经提供了足够的
证据后,仍然要求
申请人补充材料。长此以往,滥发RFE便成为影响移民局工作效率的固疾。移民局曾几
度以备忘录的方式,
澄清发放补证通知的标准,并要求移民官予以执行。
移民局在备忘录中反复澄清移民申请的举证标准。在此,我们对美国法律中的两种不同
举证标准做一简单
介绍。一般而言,民事和行政法程序中的举证标准是“占优势的证据” (
preponderance of the
evidence),而刑法程序的举证标准则是“确凿无疑的证据”(beyond reasona... 阅读全帖
f*******8
发帖数: 1430
12
我觉着等国会复会后会有一场很大的immigration debate. 即使移民团体不推动,像
NUMEBERSUSA这种势力强大的anti-immigration group也会强力推动的, 因为这些anti
所一直依赖的attrition through enforcement的政策随着奥巴马的新政策而瓦解。
让我们拭目以待他们狗咬狗。
****************************************************************************
****
Does Pres. Obama's new amnesty attempt mean E-Verify bill wouldn't work?
By Roy Beck, Thursday, August 25, 2011, 7:20 PM EDT - posted on NumbersUSA
Has Pres. Obama convinced ANTI-amnesty activists to give up on keeping
illegal aliens from holding... 阅读全帖
H********g
发帖数: 43926
13
惨,已经被patent了
Patent Acquisition and Assertion by a (Non-Inventor) First Party Against a
Second Party
US 20080270152 A1
ABSTRACT
Methods for a first party to acquire and assert a patent property against a
second party are disclosed. The methods include obtaining an equity interest
in the patent property. The methods further include writing a claim within
the scope of the patent property. The claim is written to cover a product of
the second party where the product includes a secret aspect. The me... 阅读全帖
H********g
发帖数: 43926
14
刚才看google play store那个帖子,在youtube评论里看到的:
Patent Acquisition and Assertion by a (Non-Inventor) First Party Against a
Second Party
US 20080270152 A1
ABSTRACT
Methods for a first party to acquire and assert a patent property against a
second party are disclosed. The methods include obtaining an equity interest
in the patent property. The methods further include writing a claim within
the scope of the patent property. The claim is written to cover a product of
the second party where the product incl... 阅读全帖
n********n
发帖数: 8336
15
The existence of God using logical absolutes
This is an attempt to demonstrate the existence of God using logical
absolutes. The oversimplified argument, which is expanded in outline form
below, goes as follows: Logical absolutes exist. Logical absolutes are
conceptual by nature--are not dependent on space, time, physical properties,
or human nature. They are not the product of the physical universe (space,
time, matter) because if the physical universe were to disappear, logical
absolutes w... 阅读全帖
b******n
发帖数: 592
16
来自主题: Programming版 - C++的exception大家常用吗?
assert is different than exception. And assert depends on the build, you
only
have it in DEBUG build. when assert fails, the program has to terminate.
Imagine
a library you use has all asserts, no error code. In your case,
assert is a exception you never catch, meaning you can't use that exception
information to recover or do anything.
of course there is a proformance hit. You shouldn't worry about it anyway.
normally it is not an issue to write safer code while losing a little bit
on performanc... 阅读全帖
e****i
发帖数: 2152
17
【 以下文字转载自 Military 讨论区 】
发信人: erkuai (三天不上bbs,赶得上刘少奇), 信区: Military
标 题: On the Jews and Their Lies, 1543
发信站: BBS 未名空间站 (Wed Jan 12 23:21:23 2011, 美东)
by Martin Luther (1483-1546)
Translated by Martin H. Bertram
copyright © 1971 Fortress Press & Augsburg Fortress - On the Jews and
Their Lies is from Luther’s Works Volume 47. Augsburg Fortress is the
publishing ministry of the Evangelical Lutheran Church in America.
Funded through sales revenue, Augsburg Fortress is called to provide
produ... 阅读全帖
e****i
发帖数: 2152
18
来自主题: Military版 - On the Jews and Their Lies, 1543
by Martin Luther (1483-1546)
Translated by Martin H. Bertram
copyright © 1971 Fortress Press & Augsburg Fortress - On the Jews and
Their Lies is from Luther’s Works Volume 47. Augsburg Fortress is the
publishing ministry of the Evangelical Lutheran Church in America.
Funded through sales revenue, Augsburg Fortress is called to provide
products and services that communicate the Gospel, enhance faith, and
enrich the life of the Christian community from a Lutheran perspective.
Part I
I had mad... 阅读全帖
l**i
发帖数: 8144
19
来自主题: Military版 - Anthropic principle
简单地讲 就是谋事在人 成事在天
认为社会发展沿着某个预定方向发展的理论 都是傻逼理论
--------------------------------------
Anthropic principle
From Wikipedia, the free encyclopedia
In astrophysics and cosmology, the anthropic principle is the philosophical
argument that observations of the physical Universe must be compatible with
the conscious life that observes it. Some proponents of the argument reason
that it explains why the Universe has the age and the fundamental physical
constants necessary to accommodate conscious life. As a ... 阅读全帖
R****a
发帖数: 6858
20
来自主题: Military版 - 大棋局与9/11
大棋局与9/11
来源: ognc 于 2013-02-22 16:08:44[档案] [博客] [旧帖] [转至博客] [给我悄悄
话] 本文已被阅读:63次
字体:调大/调小/重置 | 加入书签| 打印| 所有跟帖 | 加跟贴| 查看当前最热讨论主题
The Moral Decoding of 9-11
By Prof. John McMurtry
(Journal of 9/11 Studies) - I was sceptical of the 9-11 event from the first
time I saw it on television. It was on every major network within minutes.
All the guilty parties were declared before any evidence was shown. The
first questions of any criminal investigation were erased. Who had the most
compelling motives for... 阅读全帖
H*******s
发帖数: 793
21
Assertion of facts (what actually happened) are different from assertions of
opinions (what people THINK happened). Assertion of opinions aren't subject
to libel/slander, while assertion of facts are.
M*****8
发帖数: 17722
22
来自主题: ebiz版 - 大叔不要迷信organic食品

......................
正确,这才是最重要的。
原因在此:
http://www.freewebs.com/lasalocid/
Atrial Fibrillation Caused Or Worsened By Lasalocid Residue In Eggs
1998 - 2005 updated Nov 2006 and May 2007
Richard Gee
This Paper in PDF Format
Lasalocid is a veterinary "antibiotic" which is given as a feed supplement
to certain farm animals and poultry including birds destined to become
layers. You can read all about this highly toxic heart poison and how it is
seriously afflicting UK egg production in this April 2... 阅读全帖
w********t
发帖数: 5586
23
Credit Card Chargeback Rights
The following information is meant to advise you generally of your rights
under federal and California state law to challenge credit card charges you
dispute. These rights are called "credit card chargeback rights." The
federal laws are found in 15 United States Code §§ 1666, 1666i, and 1640(e
) and in 12 Code of Federal Regulations §§ 226.12(c) and 226.13. The
California laws are found in the California Civil Code at §§ 1747 - 1748.
95.
When you apply for a Visa ca... 阅读全帖
w****x
发帖数: 2483
24
void MarkMap(const char* szStrs[], int n, int nBegIndex, bool chrMap[26][26])
{
assert(szStrs && nBegIndex >= 0 && n >= 0);
if (n <= 1) return;
int nDiv = -1;
for (int i = 0; i < n-1; i++)
{
char tmp1 = *(szStrs[i] + nBegIndex);
char tmp2 = *(szStrs[i+1] + nBegIndex);
assert(((tmp1 >= 'a' && tmp1 <= 'z') || tmp1 == 0));
assert(((tmp2 >= 'a' && tmp2 <= 'z') || tmp2 == 0));
if (tmp1 != 0 && nDiv < 0)
nDiv = i;
if (tmp1... 阅读全帖
i**********e
发帖数: 1145
25
代码是没错,但是 hit 到一个你写的 assert.
试试 input [1,3] , x = 0
会 hit 以下的这个 assert:
assert(nRgt <= nLft && (a <= nRgt || a >= nLft) && (b <= nRgt || b >= nLft))
把 assert 去掉就好。
另外赞你另一方面的思路,但是如果你加多些解释会更好,不然读者要花很多时间来去
解读你的code.
w****x
发帖数: 2483
26
来自主题: JobHunting版 - binary tree的in-order iterator怎么写?
这题作的不下5遍了, 说实话, 第一次做还挺不容易的:
============带parent===========================
void InOrderPrint(NODE* pRoot)
{
assert(pRoot);
NODE* pCur = pRoot;
while (pCur != NULL)
{
while (pCur->pLft != NULL)
{
cout<nVal< pCur = pCur->pLft;
}
cout<nVal< //The ending condition is tricky but simple
while (pCur != NULL)//use "pCur != NULL" rather than "pCur->pParent
!= NULL"
... 阅读全帖
w****x
发帖数: 2483
27
来自主题: JobHunting版 - 做了一下merge BST
//Merge two BST
//O(n) solution
//1. Change BST into linked list
//2. Merge 2 linked lists
//3. Change linked list into a balanced BST
struct NODE
{
int nVal;
NODE* pLft;
NODE* pRgt;
NODE(int n) : nVal(n), pLft(NULL), pRgt(NULL) {}
};
////////////////////change BST to linked list///////////////////////////////
void _inner_chng_link(NODE* pNode, NODE*& ph, NODE*& pt)
{
if (NULL == pNode) return;
NODE* pLft1 = pNode;
NODE* pLft2 = pNode;
_inner_chng_link(pNode->pLft... 阅读全帖
d**s
发帖数: 98
28
http://zhedahht.blog.163.com/blog/static/2541117420071289522817
程序员面试题精选100题(02)-设计包含min函数的栈[数据结构]
2007-02-28 21:52:28| 分类: 栈 | 标签:编程 就业 找工作 |字号大中小 订阅
题目:定义栈的数据结构,要求添加一个min函数,能够得到栈的最小元素。要求函数
min、push以及pop的时间复杂度都是O(1)。
分析:这是去年google的一道面试题。
我看到这道题目时,第一反应就是每次push一个新元素时,将栈里所有逆序元素排序。
这样栈顶元素将是最小元素。但由于不能保证最后push进栈的元素最先出栈,这种思路
设计的数据结构已经不是一个栈了。
在栈里添加一个成员变量存放最小元素(或最小元素的位置)。每次push一个新元素进
栈的时候,如果该元素比当前的最小元素还要小,则更新最小元素。
乍一看这样思路挺好的。但仔细一想,该思路存在一个重要的问题:如果当前最小元素
被pop出去,如何才能得到下一个最小元素?
因此仅仅只添加一个成员变量存放最小元素(或最... 阅读全帖
w****x
发帖数: 2483
29
来自主题: JobHunting版 - 攒人品,Twitter 电面题目

写一个
//Merge two BST
//O(n) solution
//1. Change BST into linked list
//2. Merge 2 linked lists
//3. Change linked list into a balanced BST
struct NODE
{
int nVal;
NODE* pLft;
NODE* pRgt;
NODE(int n) : nVal(n), pLft(NULL), pRgt(NULL) {}
};
////////////////////change BST to linked list///////////////////////////////
void _inner_chng_link(NODE* pNode, NODE*& ph, NODE*& pt)
{
if (NULL == pNode) return;
NODE* pLft1 = pNode;
NODE* pLft2 = pNode;
_inner_chng_link(pNode-... 阅读全帖
f**********t
发帖数: 1001
30
来自主题: JobHunting版 - Linkedin 电面 面经x2
void shuffle(vector &vi) {
for (size_t i = 0; i < vi.size(); ++i) {
size_t k = rand() % (vi.size() - i);
swap(vi[i], vi[i + k]);
}
for_each(vi.begin(), vi.end(), [](int x) {
cout << x << ' ';
});
cout << endl;
}
/*
* Example:
* WordDistanceFinder finder = new WordDistanceFinder(Arrays.asList("the",
"quick", "brown", "fox", "quick"));
* assert(finder.distance("fox","the") == 3);
* assert(finder.distance("quick", "fox") == 1);
*/
class WordDistanceFinder {
vector... 阅读全帖
l*****n
发帖数: 204
31
来自主题: Living版 - lien 还在,到底要不要close?
我也觉得tricky,但是就是不知道所以然,也说不出道道来。the title insurance 还
有 comprehensive 的?真的第一次听说。不过够呛,title company 似乎只想撇清与
这个lien的关系。
不过,打电话问state tax,他们说lien是跟着前房主走,似乎与房子没有关系,不知
道可靠不?
另外,不close 的话,估计他们会说是我的责任,除了appraisal以外,他们说还需要
付title report fee。不知道还有什么?
以下是所谓的indemnity 的关键部分,各位说公平吗?好像并不保护我呀。
in the consideration of the issuance of said title insurance policy, the
undersigned covenant and agree with the Company (1) to forever fully protect
, defend and save harmless the Company from and against the above ment... 阅读全帖
t******l
发帖数: 10908
32
social science 都不是严格意义上的 science,而是 social study。
所以也没有人根据目前的情况来 assert 将来,如果去掉了 race factors,UT 将来一
定不能 reach UT 想达到的 diversity mix。
换言之,你的 assertion 只能 assert 现在,不能 assert 将来。对将来,
technically,你是在假设所有因子都不会变动的情况下,从目前的点向前做 blind
extrapolation。

science
F*V
发帖数: 3978
33
来自主题: CanadaNews版 - 大棋局与9/11
大棋局与9/11
来源: ognc 于 2013-02-22 16:08:44[档案] [博客] [旧帖] [转至博客] [给我悄悄
话] 本文已被阅读:63次
字体:调大/调小/重置 | 加入书签| 打印| 所有跟帖 | 加跟贴| 查看当前最热讨论主题
The Moral Decoding of 9-11
By Prof. John McMurtry
(Journal of 9/11 Studies) - I was sceptical of the 9-11 event from the first
time I saw it on television. It was on every major network within minutes.
All the guilty parties were declared before any evidence was shown. The
first questions of any criminal investigation were erased. Who had the most
compelling motives for... 阅读全帖
E*****m
发帖数: 25615
34
来自主题: TrustInJesus版 - 信徒常見邏輯謬誤列表 (ZT)
AD HOMINEM
AD HOMINEM
Latin for "to the man".
This is attacking the arguer and not the argument.
Example: The Reverend is a known Biblical fundamentalist, so her objections
to evolution need not be taken seriously.
Example 2: That Biblical scholar is saying such and such because he doesn’t
know Jesus as his personal savior.
Care must be taken to state problems with a person’s argument instead of
attacking the person.
—————————————————
STRAW MAN
Caricaturing a position to make it easier to attack... 阅读全帖
j*****7
发帖数: 10575
35
来自主题: TrustInJesus版 - [马丁路德-意志的捆绑] 9 神的主权
Sect. IX. — THIS, therefore, is also essentially necessary and wholesome
for Christians to know: That God foreknows nothing by contingency, but that
He foresees, purposes, and does all things according to His immutable,
eternal, and infallible will. By this thunderbolt, “Free-will” is thrown
prostrate, and utterly dashed to pieces. Those, therefore, who would assert
“Free-will,” must either deny this thunderbolt, or pretend not to see it,
or push it from them. But, however, before I establish th... 阅读全帖
J*******g
发帖数: 8775
36
from Wiki.http://en.wikipedia.org/wiki/Evidence
Evidence, broadly construed, is anything presented in support of an
assertion. This support may be strong or weak. The strongest type of
evidence is that which provides direct proof of the truth of an assertion.
At the other extreme is evidence that is merely consistent with an assertion
but does not rule out other, contradictory assertions, as in circumstantial
evidence.
Evidence doesn't naturally prove or disprove things. Evidence in
Christianity... 阅读全帖
J*******g
发帖数: 8775
37
来自主题: TrustInJesus版 - 比反基更無聊的
证据是用来支持一个观点的东西。不必直接证明这个观点。
可以看看wiki
Evidence, broadly construed, is anything presented in support of an
assertion. This support may be strong or weak. The strongest type of
evidence is that which provides direct proof of the truth of an assertion.
At the other extreme is evidence that is merely consistent with an assertion
but does not rule out other, contradictory assertions, as in circumstantial
evidence.
J*******g
发帖数: 8775
38
来自主题: TrustInJesus版 - 祈祷的结果
http://en.wikipedia.org/wiki/Evidence
Evidence, broadly construed, is anything presented in support of an
assertion. This support may be strong or weak. The strongest type of
evidence is that which provides direct proof of the truth of an assertion.
At the other extreme is evidence that is merely consistent with an assertion
but does not rule out other, contradictory assertions, as in circumstantial
evidence.
l******t
发帖数: 490
39
来自主题: TrustInJesus版 - 基和穆的神应该是同一个吧?
解答:Allah為什麼有時候用複數代詞“我們”
The Quran, Allah and Plurality Issues (Sam Shamoun)
The Quran, much like the Holy Bible, uses plural pronouns for God even more
so than what we find in God’s true Word. Here are several examples:
This is part of the tidings of the things unseen, which We reveal unto thee
(O Apostle!) by inspiration: Thou wast not with them when they cast lots
with arrows, as to which of them should be charged with the care of Mary:
Nor wast thou with them when they disputed (the point). S... 阅读全帖
r***l
发帖数: 67
40
assert is much differnt.
Assert will abort your program at runtime if something goes wrong. It is a way
to complement unit testing. It is to test how your code works, and unit
testing is to test what your code does.
Normally, assert concerns about invariant - something should always be true in
your program, e.g. thread_in_pool >= 0. If the invariant is false, program
should terminate right there.
Assert is very important, but hard to use it right.

太晚
很多i
S*******h
发帖数: 7021
41
在Eclipse里写了一个HelloWord program. 用了Assert statement. Tutorial说需要
先run java -ea command 去enable assert
public class HellowWorld {
public static void main(String[] args) {
int x = 5;
int y = 7;
assert (x > y): "stuff";
System.out.println("passed");
}
}
1. java -ea HelloWorld 只能在command line console 底下跑吗? 有没有办法让它
在 Eclipse->Run application 前 在Eclipse里 run 这command?
2. 在command line console 里试了 C:\workspace\Test\src> java -ea HelloWorld
结果返回 "could not find the main class HelloW... 阅读全帖
e****x
发帖数: 692
42
Thanks a lot for your inputs.
Now it can launch. However, will freeze once I drag the GUI.
Any idea?
=========================================
(process:4978): GLib-GObject-CRITICAL **: gtype.c:2710: You forgot to call g
_type_init()
(process:4978): GLib-CRITICAL **: g_once_init_leave: assertion `
initialization_value != 0' failed
(process:4978): GLib-GObject-CRITICAL **: gtype.c:2710: You forgot to call g
_type_init()
(process:4978): GLib-GObject-CRITICAL **: gtype.c:2710: You forgot to call g
_... 阅读全帖
s*********t
发帖数: 600
43
没人转这个咩?老Poo的2012年新年报告
版主给m下,再给一个包子吧:)
——————————————————————
科学追求的事实和谬论——2011中科院神经所年会蒲慕明所长报告
方琪
今年的神经所年会蒲慕明所长的报告继续由我根据录音整理,不知是不是独家,在年末
愿与有志于科学的同学们共勉~^^
科学追求的事实和谬论
Facts and Fallacies in Science
Mu-ming Poo
2011.12.29 16:30-17:15
好,我们今年年会非常热烈,大家都看到了,我们年年有进展,今年很多进展的报告大
家都觉得很兴奋,我想先讲今年所里几件大事吧,第一件大事是现在所里的领导增加了
鲜血,大家可能还不知道,王燕老师是我们所里正式的学术副所长,舒友生老师是我们
的党委副书记[在座一同学说道:“舒老师今天实验室来了新样品,估计在做实验今天
……”],还有王佐仁老师是所长助理,我们最近又来了几个新的师长,最新的是昨天
到的张翼凤老师,Harvard博士后,UCSD的PhD,有些同学听过她的报告,有些同学没有
听过,可以给她安排一场,晚上的seminar.
下面为大家讲... 阅读全帖
p*****m
发帖数: 7030
44
不喜欢

没人转这个咩?老Poo的2012年新年报告
版主给m下,再给一个包子吧:)
——————————————————————
科学追求的事实和谬论——2011中科院神经所年会蒲慕明所长报告
方琪
今年的神经所年会蒲慕明所长的报告继续由我根据录音整理,不知是不是独家,在年末
愿与有志于科学的同学们共勉~^^
科学追求的事实和谬论
Facts and Fallacies in Science
Mu-ming Poo
2011.12.29 16:30-17:15
好,我们今年年会非常热烈,大家都看到了,我们年年有进展,今年很多进展的报告大
家都觉得很兴奋,我想先讲今年所里几件大事吧,第一件大事是现在所里的领导增加了
鲜血,大家可能还不知道,王燕老师是我们所里正式的学术副所长,舒友生老师是我们
的党委副书记[在座一同学说道:“舒老师今天实验室来了新样品,估计在做实验今天
……”],还有王佐仁老师是所长助理,我们最近又来了几个新的师长,最新的是昨天
到的张翼凤老师,Harvard博士后,UCSD的PhD,有些同学听过她的报告,有些同学没有
听过,可以给她安排一场,晚上的seminar.
下... 阅读全帖
m*****s
发帖数: 2227
45
我们有很多postdoc在国外,有少数做得不错,大部分都是failure
。为什么failure?对实验室不满,要换实验室,一个实验室不行要换另一个实验室,
很多学生都是跳实验室,跳好几个实验室,都是一事无成。有少数留在一个实验室的做
得不错。这个就是关键,你要做科学,你要真正做成功,你必须要有虚心。你还是一个
初始的人,你到人家的实验室,人家给你的意见你不听,那人家要你干什么呢?人家给
你support么?有些好的人说我给你support,就算你聪明,你去做吧,也做不成。有些
人不是那么tolerant,你到我这里来,现在经费这么困难,我找经费给你做,给实验室
你做,你却做你的题目,根本不可能成的题目,又不听我的意见,马上把你fire了。有
很多学生换实验室,不是他真的不想留下来,他不能跟老板相处,他就换一个实验室,
老板也不愿意接手。还是年轻的时候,没有humanity,人家不是你admire的诺贝尔奖得
主,人家或许只是比你多几年经验,你不能不接收人家的意见,否则你就不要到这个实
验室来。这是很重要的,我知道很多同学就没有这个flexibility,我们的老板怎么讲
都不听,就是... 阅读全帖
l********8
发帖数: 91
46
static key word: what is static in front of a function declaration? what is
static key word for a variable inside a function definition? what is static
keyword for a var outside a function definition.
对于变量而言,static的变量是放在静态存储区的(跟全局变量放在一起的),但是不
具备全局可见性,也就是只能在申明的函数中才能看到。
对于函数而言,static申明的函数没有全局可见性。
what is the difference pass by value or pass by reference. when to use them?
一般通过变量以及宏定义来进行数据的传递是为了方便调试。因为在调试时候,一个经
常用到的数据如果要进行修改的话只需要在宏定义或者变量申明的地方改一下就可以了。
what is const and volatile keywords for?
关键词cons... 阅读全帖
l********8
发帖数: 91
47
static key word: what is static in front of a function declaration? what is
static key word for a variable inside a function definition? what is static
keyword for a var outside a function definition.
对于变量而言,static的变量是放在静态存储区的(跟全局变量放在一起的),但是不
具备全局可见性,也就是只能在申明的函数中才能看到。
对于函数而言,static申明的函数没有全局可见性。
what is the difference pass by value or pass by reference. when to use them?
一般通过变量以及宏定义来进行数据的传递是为了方便调试。因为在调试时候,一个经
常用到的数据如果要进行修改的话只需要在宏定义或者变量申明的地方改一下就可以了。
what is const and volatile keywords for?
关键词cons... 阅读全帖
d*z
发帖数: 150
48
来自主题: Science版 - Re: yes....1413
hehe , more than 600 lines:
#include
#include
#include
#include
#include
#include
#include
#ifdef _WIN32
typedef __int64 longlong;
using namespace std;
#else
typedef long long longlong;
#endif
#ifdef _DEBUG
#include
#define ASSERT(x) assert(x)
#else
#define ASSERT(x)
#endif
#define MAX_NUM 10
//enlarge CACHE_LIMIT so that some expression will be saved in memory. This
will speed the program,
//but then we could not print
f**d
发帖数: 768
49
【 以下文字转载自 Biology 讨论区 】
发信人: squirrabbit (松鼠兔), 信区: Biology
标 题: 科学追求的事实和谬论—2011年神经所蒲慕明报告ZT
发信站: BBS 未名空间站 (Sat Dec 31 12:25:06 2011, 美东)
没人转这个咩?老Poo的2012年新年报告
版主给m下,再给一个包子吧:)
——————————————————————
科学追求的事实和谬论——2011中科院神经所年会蒲慕明所长报告
方琪
今年的神经所年会蒲慕明所长的报告继续由我根据录音整理,不知是不是独家,在年末
愿与有志于科学的同学们共勉~^^
科学追求的事实和谬论
Facts and Fallacies in Science
Mu-ming Poo
2011.12.29 16:30-17:15
好,我们今年年会非常热烈,大家都看到了,我们年年有进展,今年很多进展的报告大
家都觉得很兴奋,我想先讲今年所里几件大事吧,第一件大事是现在所里的领导增加了
鲜血,大家可能还不知道,王燕老师是我们所里正式的学术副所长,舒友生老师是我们
的党委副书记[在座一同学说道:... 阅读全帖
v**********m
发帖数: 5516
50
来自主题: _pennystock版 - soros的精神导师:Karl Popper的生平
Sir Karl Raimund Popper, CH FRS[1] FBA (28 July 1902 – 17 September 1994)
was an Austro-British[2] philosopher and a professor at the London School of
Economics.[3] He is regarded as one of the greatest philosophers of science
of the 20th century;[4][5] he also wrote extensively on social and
political philosophy.
Popper is known for his attempt to repudiate the classical observationalist
/ inductivist form of scientific method in favour of empirical falsification
. He is also known for his oppo... 阅读全帖
首页 上页 1 2 3 4 5 6 7 8 9 10 下页 末页 (共10页)