由买买提看人间百态

topics

全部话题 - 话题: false
首页 上页 1 2 3 4 5 6 7 8 9 10 下页 末页 (共10页)
j*******g
发帖数: 4
1
来自主题: JobHunting版 - 弱弱的问一个问题
见过很多次这个题目了,一直没有招,下面写了一个又臭又长的, 方法很笨, 求建议
, 欢迎批评和指正
这样的代码面试可以通过吗?
////////////////////////////////////////////////////////////////
#include
#include
using namespace std;
//假设16位的整型
// -32768 , +32767
const char MAX_INT[] = "32767";
const char MIN_INT[] = "32768";
const int MAX_STRLEN = 5;
bool my_atoi(const char *str, int &res)
{
if(str == NULL)
{
cout << "Invalid pointer" << endl;
return false;
}

int index = 0;

if(str[index] == '-' ||... 阅读全帖
j********e
发帖数: 1192
2
来自主题: JobHunting版 - google scramble string O(n) 解法
我没有说字符集相同就能scramble,字符集相同是必要条件,而不充分。
我的做法是,先找到一个位置i在s1,j在s2使得分割后的4个字符串两两
有相同的字符集(i=j 或者i=N-j)。然后接着对这2对字符串继续做同样
的事情连寻找分割位置。这样递归下去,如果有某对字符串无法找到分割
位置,则表示失败。否则,最后分隔最小的字符串只有一个字符。就可以
判断scramble成功。
问题是,如果有多个分割位置,是否任选一个都可以?如果必须测试每个可能的分割位置,那复杂度就不好说了。
下面是我的简单实现代码,通过了leetcode的online judge (包括judge large)。这段代码中会处理所有可能的分割位置。如果只选第一个可能的分割位置,有一个测试失败了。
#include
#include
#include
#include
using namespace std;
#define BITMAP_LEN 256
bool compare_char_set(const char *s1, con... 阅读全帖
C***U
发帖数: 2406
3
我在网上judge large的时候有几个例子出错了 错误的比率很小
我把例子拷贝到我自己机器上答案是对的
不知道为什么
这个是我的code 用recursive写的
bool existHelper(vector > &board, vector > &
indicator, int row, int column, string word, int index){
if(index == word.size()) {
return true;
}
if(row < 0 || row >= board.size() || column < 0 || column >= board[0].
size()) {
return false;
}
if(indicator[row][column]){
return false;
}
if(board[row][column] != word[index]) {
retur... 阅读全帖
c***d
发帖数: 26
4
来自主题: JobHunting版 - [难题求助] leetcode wordsearch
这题野蛮暴力就能通过大case呀。
public class Solution {
public boolean exist(char[][] board, String word) {
// Start typing your Java solution below
// DO NOT write main() function
if (board==null) return false;
boolean visited[][] = new boolean[board.length][board[0].length];
for(int i = 0; i < board.length; i++) {
for(int j = 0; j < board[0].length; j++) {
if (helper(board, visited, word, i, j, 0)) return true;
}
}
... 阅读全帖
c******t
发帖数: 391
5
来自主题: JobHunting版 - 明天A家onsite
感谢分享!
第一轮算括号的题,想到两种解法,用counter算左右括号数,以及压栈比较。
//For '(,)' only, use counter, left and right are half of length, e.g. for "
(())", the call
is validParen(2,2,"(())",0).
public static boolean validParen(int left, int right, String str, int
index){
if(left==0&&right==0)return true; //base case
if(str.length()%2==1)return false; //length must be even
if(left>right)return false;
if(left<0||right<0)return false;
if(str.charAt(index)=='(') return validParen(le... 阅读全帖
b*2
发帖数: 94
6
来自主题: JobHunting版 - 一道字符串题目
当时的全部测试:
match("*","abc") //true
match("*c","abc") //true
match("*a","abc") //false
match("a*","abc") //true
match("a?","abc") //false
match("ab?","abc") //true
match("a?c","abc") //true
match("*bc","abcbc") //true
match("a*b*c","abc") //true

match("*","") //true
match("*a","bac") //false
match("a*b","ab") //true
match("a?b","ab") //false
match("a**bc","acbc... 阅读全帖
w****x
发帖数: 2483
7
/*Validate if a given string is numeric.
Some examples:
"0" => true
" 0.1 " => true
"abc" => false
"1 a" => false
"2e10" => true
*/
bool isNumber(const char *s) {

bool bIntNum = false;
int nCurState = 1;
while (true)
{
if (nCurState == 1)
{
while (*s == ' ')
s++;

if (*s == '+' || *s == '-')
s++;

if (*s >= '0' && *s <= ... 阅读全帖
w****x
发帖数: 2483
8
/*Validate if a given string is numeric.
Some examples:
"0" => true
" 0.1 " => true
"abc" => false
"1 a" => false
"2e10" => true
*/
bool isNumber(const char *s) {

bool bIntNum = false;
int nCurState = 1;
while (true)
{
if (nCurState == 1)
{
while (*s == ' ')
s++;

if (*s == '+' || *s == '-')
s++;

if (*s >= '0' && *s <= ... 阅读全帖
c*****2
发帖数: 34
9
来自主题: JobHunting版 - 狗店面,求BLESS
第一题这样做可以吗?
做pre-order traversal,如果两个node相同比较parent list是否相同。
然后递归看左右子树是否相同。
public class TreeNode {
TreeNode left;
TreeNode right;
int val;
ArrayList parents = new ArrayList();
public TreeNode(int val) {this.val = val;}
}
public boolean isIdentical(TreeNode t1, TreeNode t2) {
if (t1 == null && t2 == null) return true;
if (t1 == null && t2 != null) return false;
if (t1 != null && t2 == null) return false;
if (t1.val != t2.val) return false;
... 阅读全帖
n*p
发帖数: 298
10
in order traversal
要用一个变量来存前一个Node的值。但发现有时候值没有被更新,结果是错的,是因为
Java的passing by value的原因吗?代码如下:
public boolean isValidBST(TreeNode root) {
// Start typing your Java solution below
// DO NOT write main() function
if (root == null) return true;
//if (root.left == null && root.right == null) return true;

Integer preVal = Integer.MIN_VALUE;
return inOrder (root, preVal);

}

public boolean inOrder(TreeNode root, Integer preVal... 阅读全帖
j*****y
发帖数: 1071
11
来自主题: JobHunting版 - F面经
写了一个,欢迎测试
#include
#include
#include
#include
#include
using namespace std;
bool isNumber(string s)
{
if(s[0] == '+' || s[0] == '-' || s[0] == '(' || s[0] == ')')
{
return false;
}
return true;
}
int helper(int a, int b, char c)
{
if(c == '+')
{
return a + b;
}
else
{
return a - b;
}
}
bool valid(vector &s)
{
stack v;
stack c;
for(int i = 0; i < s.size(); ++i)
... 阅读全帖
r****m
发帖数: 70
12
来自主题: JobHunting版 - F面经
boolean validate(String expression){
String expr = expression.trim();
boolean expectNum = true;
int numOfParentheses = 0;
int i = 0;
while(i < expr.length()){
if(expr.charAt(i) == '('){
if(!expectNum) return false;
numOfParentheses++;
i++;
} else if (expr.charAt(i) == ')'){
if(expectNum || numOfParentheses < 1) return false;
numOfParentheses--;
... 阅读全帖
j*****y
发帖数: 1071
13
来自主题: JobHunting版 - F面经
写了一个,欢迎测试
#include
#include
#include
#include
#include
using namespace std;
bool isNumber(string s)
{
if(s[0] == '+' || s[0] == '-' || s[0] == '(' || s[0] == ')')
{
return false;
}
return true;
}
int helper(int a, int b, char c)
{
if(c == '+')
{
return a + b;
}
else
{
return a - b;
}
}
bool valid(vector &s)
{
stack v;
stack c;
for(int i = 0; i < s.size(); ++i)
... 阅读全帖
r****m
发帖数: 70
14
来自主题: JobHunting版 - F面经
boolean validate(String expression){
String expr = expression.trim();
boolean expectNum = true;
int numOfParentheses = 0;
int i = 0;
while(i < expr.length()){
if(expr.charAt(i) == '('){
if(!expectNum) return false;
numOfParentheses++;
i++;
} else if (expr.charAt(i) == ')'){
if(expectNum || numOfParentheses < 1) return false;
numOfParentheses--;
... 阅读全帖
r*c
发帖数: 167
15
//矩阵求连接图
#include
#include
#include
#include
#include
using namespace std;
enum ColorEnum{White, Black};
struct Cell
{
int row;
int col;
Cell(int r, int c): row(r), col(c){}
};
struct Cluster{
bool visited;
vector vec;
Cluster(int i, int j) : visited(false) {
vec.push_back(Cell( i, j));
}
bool isWithinRange(const Cell& a, const Cell& b){
return abs(a.row - b.row) <= 1 ... 阅读全帖
r*c
发帖数: 167
16
//矩阵求连接图
#include
#include
#include
#include
#include
using namespace std;
enum ColorEnum{White, Black};
struct Cell
{
int row;
int col;
Cell(int r, int c): row(r), col(c){}
};
struct Cluster{
bool visited;
vector vec;
Cluster(int i, int j) : visited(false) {
vec.push_back(Cell( i, j));
}
bool isWithinRange(const Cell& a, const Cell& b){
return abs(a.row - b.row) <= 1 ... 阅读全帖
s***e
发帖数: 403
17
来自主题: JobHunting版 - wildcard matching 大case runtime error
我对这个的理解是
把pattern按照*分开成子串
然后按照顺序依次搜索
在开头和最后的串要特别调整一下.
class Solution {
public:
#define charMatch(s, p) (p == '?' || p == s)
int subStr (const char* s, int start, const char* p, int len)
{
while (s[start] != 0)
{
if (charMatch (s[start], p[0]))
{
bool match = true;
for (int j = 1; j < len; ++j)
if (s[start + j] == 0)
... 阅读全帖
S********s
发帖数: 29
18
来自主题: JobHunting版 - G家题讨论: harry potter 走矩阵
example code of blaze's solution:
import java.util.Arrays;
import java.util.Random;
/*
* http://www.mitbbs.com/article_t1/JobHunting/32611137_0_1.html
*/
public class HarryPotMatrix {
Integer[][] w;
Integer m, n;
Integer[][] f;
public void initialize(int i, int j) {
Random r = new Random();
m = i;
n = j;
w = new Integer[m][n];
for (int l = 0; l < m; l++) {
for (int h = 0; h < n; h++) {
w[l][h] = -1 * r.nextInt(20... 阅读全帖
y*****h
发帖数: 22
19
public boolean isMultipleDuplicate(String s) {
int patternPos = 0, patternEnd = 0;
for(int i=1; i if(s.charAt(i) != s.charAt(patternPos)) {
patternPos = 0;
patternEnd = i;
} else {
if(++patternPos > patternEnd && i != s.length()-1) {
patternPos = 0;
}
}
}
return patternPos>patternEnd && patternEnd>0;
}
Result:
abcabcabc: true
bcdbcdbcde: false
abcdabcd: true
xyzxy: false
aaa... 阅读全帖
f**********t
发帖数: 1001
20
来自主题: JobHunting版 - 这里牛人多再问个难题
写个暴力的,要求状态DP的地方高攀不起
void NumOfBoardLayouts(vector> &board, size_t x, size_t y, int
*res) {
//for 1 * 2 board
size_t row = board.size();
size_t col = board[0].size();
if (x == row) {
++*res;
return;
}
for (size_t i = x; i < row; ++i) {
for (size_t k = y; k < col; ++k) {
if (board[i][k] == true) {
continue;
} else {
if (k + 1 < col && board[i][k + 1] == false) {
board[i][k] = true;
board[i][k + 1] = true;
... 阅读全帖
h*********d
发帖数: 336
21
来自主题: JobHunting版 - 大牛帮我看一段code
phone interview, 实现一个in-memory filesystem. 刚开始面试,还没有摸到门路,
请大牛指点
Write an in memory filesystem! This is a simplified file system that only
supports directories. Your code needs to read from a file and parse the
commands listed below.
cd - Changes the current working directory. The working
directory begins at '/'. The special characters '.' should not modify the
current working directory and '..' should move the current working directory
to the parent.
mkdir - Creates a new dire... 阅读全帖
S*******C
发帖数: 822
22
import java.util.Stack;
/*
* Given Tree and Node n and int k, print all node which are at physical
distance <=k from n
* @Amazon intern
*/
public class Solution {
public static void main(String args[]){
Solution solution = new Solution();
TreeNode a = new TreeNode(8);
TreeNode b = new TreeNode(6);
TreeNode c = new TreeNode(10);
TreeNode d = new TreeNode(9);
TreeNode e = new TreeNode(12);
TreeNode f = new TreeNode(4);
TreeNode ... 阅读全帖
l*****o
发帖数: 214
23
public class NumberPickGame {

public NumberPickGame() {}

public static boolean canIForceWin(int maxNumber, int total) {
if ((maxNumber + 1) * maxNumber /2 < total) {
return false;
}
Set numbersAvailable = new HashSet();
for (int i = 1; i <= maxNumber; i++) {
numbersAvailable.add(i);
}
int[] picks = new int[maxNumber];
boolean canWin = canFirstPlayerWin(numbersAvailable, total, 0, pic... 阅读全帖
x******8
发帖数: 48
24
来自主题: JobHunting版 - FB Onsite新题,有人能看看吗?
根据mitkook2大神的代码改了一下,思路是一致的,大家参考一下
// O(n*k) time, O(n) space
boolean alibaba(int numCaves, int[] strategy) {
// survival[i] means theft can be in spot i or not on this day
boolean survival[] = new boolean[n + 2];

// init the first day
// 在头尾加一个房间,且小偷不可能出现在这两个房间(为了处理下面j - 1
和j + 1越界的情况)
Arrays.fill(survival, true);
survival[0] = false;
survival[n + 1] = false;
survival[strategy[0]] = false;

for (int i ... 阅读全帖
m******n
发帖数: 51
25
来自主题: JobHunting版 - Amazon 線上面試題
Total 4 questions.
--------------------------------------------------------------
Question 1:
1. What is the runtime complexity for the code below?
2. What is the space complexity for the code below?
Queue queue = new LinkedList() ;
public void myMethod(TreeNode root) {
if (root == null)
return;
queue.clear();
queue.add(root);
while(!queue.isEmpty()){
TreeNode node = queue.remove();
if(node.left != null) queue.add(node.left);... 阅读全帖
m******3
发帖数: 346
26
来自主题: JobHunting版 - FLGU面经offer及杂谈
非常感谢,结合楼主发的tutorial,基本懂了,加点我理解的吧
public static boolean canIWin(int rangeMax, int target) {
if(rangeMax * (rangeMax + 1) /2 < target)
return false;
boolean[] visited = new boolean[rangeMax+1];
return recursive(0, rangeMax, target, visited);
}

private static boolean recursive(int cur, int rangeMax, int target,
boolean[] visited){
if(cur >= target) return false;
// 说明对手拿完以后,和>=target,所以对手获胜,我输
//尝试我所有可能的拿法,如果我拿了以后,对其中一个拿法,有heWin=false,则我可
以保证获... 阅读全帖
m******3
发帖数: 346
27
来自主题: JobHunting版 - FLGU面经offer及杂谈
非常感谢,结合楼主发的tutorial,基本懂了,加点我理解的吧
public static boolean canIWin(int rangeMax, int target) {
if(rangeMax * (rangeMax + 1) /2 < target)
return false;
boolean[] visited = new boolean[rangeMax+1];
return recursive(0, rangeMax, target, visited);
}

private static boolean recursive(int cur, int rangeMax, int target,
boolean[] visited){
if(cur >= target) return false;
// 说明对手拿完以后,和>=target,所以对手获胜,我输
//尝试我所有可能的拿法,如果我拿了以后,对其中一个拿法,有heWin=false,则我可
以保证获... 阅读全帖
i******t
发帖数: 798
28
来自主题: JobHunting版 - 大家看看这个题目改怎么做。
我想用interval tree 作, 不知道思路对不对 .
用 interval tree 原理 应该可以把但是 可能不能满足 效率问题?
thanks
Scenario:
---------
In our server farm, there are certain times of day in which we get a higher
number of requests. During these time-spans we want to respond by allocating
more resources, to give better service. Outside these time-spans we want to
remove resources, to save on energy.
We need to be able to know which times of day are such "Rush Hours".
Your task:
----------
Write a class which can receive time-spans ... 阅读全帖
j*******y
发帖数: 89
29
来自主题: NextGeneration版 - 不要羊穿了.抽血即可.
SAN DIEGO, Oct. 17, 2011 /PRNewswire/ -- Sequenom, Inc. (NASDAQ: SQNM), a
life sciences company providing innovative genetic analysis solutions, today
announced that its wholly-owned subsidiary, Sequenom Center for Molecular
Medicine (Sequenom CMM), launched its noninvasive proprietary MaterniT21
laboratory developed test (LDT). The MaterniT21 LDT detects a genetic
chromosomal anomaly known as Trisomy 21, the most common cause of Down
syndrome. The test is now available to physicians upon requ... 阅读全帖
h***t
发帖数: 28
30
来自主题: NextGeneration版 - 无创产前筛查--NIPT
在宝宝版学了不少东西,作为回馈,把我在孕期了解的关于NIPT综合概括了一下。希望
对大家有帮助。有不足的也欢迎补充。最后祝大家的宝宝都活泼,快乐,健康,可爱。
一 NIPT是什么?
无创产前筛查
http://www.nchpeg.org/index.php?option=com_content&view=article
二 不同公司有不同名称,实质是一样的:
http://www.bio360.net/news/show/10304.html
Sequenom Verinata Health(Illumina) Ariosa Diagnostics
Natera LifeCodexx
产品名 MaterniT21 Verifi Harmony Prenatal Test Panorama
Prenatal Test PrenaTest
国家 美国 美国 美国 美国 德国、瑞士
上市时间 2011.1 2012.3 2012.5 20... 阅读全帖
t*******r
发帖数: 22634
31
来自主题: Parenting版 - 我对AA的看法
或者我这么说,这个就是你所说的,social science 里面的
量化估测的问题。。。具体到这个问题,就是 false positive
和 false negative 的权衡问题。
对于精英藤校而言,首先是招生数量少,其次是私立,再次那
不是广大人民群众保本的东东。。。那藤校为了确保 false
positive 够低,以一定数量的 false negative 为代价。
不完美,但是至少有一定理由。
而对于州立大学,首先是招生数量大,其次是用纳税人的钱
运营的,另外还是广大人民群众的高等教育的主力。。。在
这种情况下,依据美帝的 “No Taxation wo/ Representation”
的精神,降低 false negative,以及招生过程足够透明
(否则你咋知道是不是 false negative),才是首要的
。。。所以需要广大群众看得见能监督的入学标准,保证
符合标准的娃,都能进入州大。。。
s******g
发帖数: 654
32
The IRS is going after tax cheat issue. This may explain everything.
http://www.accountingtoday.com/news/IRS-Warns-Tax-Preparer-Frau
The Internal Revenue Service has been investigating and helping prosecute a
number of tax preparers in Southern California who have been cheating the
government and their clients.
As the tax filing season is in full swing, the IRS noted that it’s
important for taxpayers to find honest, qualified tax professionals if they
need tax preparation assistance. Taxpayers a... 阅读全帖
n*****g
发帖数: 626
33
The following video is about real unemployment situation in
SAN JOSE, CALIFORNIA.
This is the consequence of voting for the Party of Food Stamp.
http://www.cbsnews.com/video/watch/?id=6987699n
http://cnettv.cnet.com/av/video/cbsnews/atlantis2/cbsnews_player_embed.swf" scale="noscale" salign="lt" type="application/x-shockwave-flash" background="#333333" width="425" height="279" allowFullScreen="true" allowScriptAccess="always" FlashVars="si=254&uvpc=http://cnettv.cnet.com/av/video/cbs... 阅读全帖
p****r
发帖数: 31
34
来自主题: Seattle版 - 这里有微软msn和hotmail组的吗?
The rate that matters is the false positive rate. Let n1 and n2 be the
number that the system time is changed by users and the number that
the system time is changed by malware, respectively. The false
positive rate is n1/(n1+n2). False-positive rate is a critical value
for evaluating the effectiveness of counter measures of security
attacks (i.e., the higher false-positive, the less effective).
No idea about the false-positive rate of this counter measure
(i.e., checking the system time). Howev... 阅读全帖
t*******y
发帖数: 10477
35
我猜你说的是“看来taper对距离影响不大”?
---------------------------------------
轮:
1. 大spool比小spool扔的远。 2500比1000扔的远。因为出同样长的线,2500转的圈少。
false
2. 上线基本要上满。道理同上。
maybe
杆:
1. 越长扔的越远,买个6.6~7 feet 的吧。
false
2. power要和饵搭配。 饵的重量要可以把杆load起来,才能扔的远。如果一个ML杆标1
/8oz ~ 1/2 oz,那就用1/4oz的饵最好。换句话说,如果你常扔1/8oz的,那就要买个L杆了。
false
3. action:软的扔的远
false
4. 第一个guide 靠近reel seat越远,扔的越远
false
5. guide环越大扔的越远
false
线:
1. 越软越细,扔的越远。
true
O***O
发帖数: 264
36
好吧,我把源代码给你贴这儿了,老刑该找我麻烦了:)
#include
#include
//函数声明
bool Win(int [4][10]);
bool Analyze(int [],bool);
int main(int argc, char* argv[])
{
//定义手中的牌
int allPai[4][10]={
{6,1,4,1},//万
{3,1,1,1},//筒
{0},//索
{5,2,3}//字
};
if (Win (allPai))
printf("Hu!\n");
else
printf("Not Hu!\n");
return 0;
}
//判断是否胡牌的函数
bool Win (int allPai[4][10])
{
int jiangPos;//“将”的... 阅读全帖
o*****e
发帖数: 379
37
来自主题: Outdoors版 - [TR] Groat Mountain
最早说的是去爬Long,中间变过一次计划,出发前两天又临时决定去爬Groat,只因
leader突然看到了NWHiker上有人贴的TR和片子,被种草了… 开始两次还很认真地找
report和地图研究,最后也懒得看了,谁知道还会不会再换地方。Groat Mountain只是
一个小山头,离它最近的major peak是5 miles之遥的twin sisters。星期六早上6点半
在Ash way P&R集合,话说我已经有年头没这么早起过床了… 往北开的路上不仅看到了
日出、还看见了月落。大概因为月亮位置已然很低,车子左侧的月亮圆盘看着不仅大,
而且极为清晰、明亮。天也很好,开出没多远就能很清楚地看到Baker了。
Groat Mountain西边不到2 miles的地方是Stewart Peak。夏天,沿着盘山公路可以一
直开到离4200 ft高的Stewart山顶很近的地方。我们三辆4WD塞了12个人尽量往上开,
最后停在了2400 ft高的一个公路转角处。再往上很快道路就完全的被积雪覆盖了,这
是最后一个方便停车的地方。我们计划的路线是沿着公路走到3520 ft高的“丫”字形
路口... 阅读全帖
s**i
发帖数: 4448
38
来自主题: TrustInJesus版 - 有什么证据证明上帝存在?
Argument from ignorance, also known as argumentum ad ignorantiam or "appeal
to ignorance" (where "ignorance" stands for: "lack of evidence to the
contrary"), is a fallacy in informal logic. It asserts that a proposition is
true because it has not yet been proven false (or vice versa). This
represents a type of false dichotomy in that it excludes a third option,
which is that there is insufficient investigation and therefore insufficient
information to prove the proposition satisfactorily to be e... 阅读全帖
a*****y
发帖数: 33185
39
来自主题: Wisdom版 - Philosophical zombie--Wiki
Philosophical zombie
A philosophical zombie or p-zombie is a hypothetical being that is
indistinguishable from a normal human being except that it lacks conscious
experience, qualia, or sentience. When a zombie is poked with a sharp object
, for example, it does not feel any pain. While it behaves exactly as if it
does feel pain (it may say "ouch" and recoil from the stimulus, or tell us
that it is in intense pain), it does not actually have the experience of
pain as a putative "normal" person d... 阅读全帖
g*****g
发帖数: 34805
40
你用的是CouchDB,实现里每个操作会打开一个http connection,没有pooling。
如果一个DB操作是10ms的话,打开一个连接通常是100ms级。有pooling的话,这些连接
可以被重用,可以大大缩短整个时间。作者这么土鳖的实现,结果就是导致到数据库的
IO轻松地成为瓶颈,语言执行的快慢完全可以忽略不计。在这个前提下Node异步的实现
即使在低并发的时候都会比servlet同步的实现快。当然还是不会比同样异步的java实
现如vert.x快。
web应用,app server到db server的connection pooling是常识。原作者跟你一样没有
常识,你还如获至宝。HelloWorld程序员真不是说的。
你如果去看另外一个评测里的实现,有常识的程序员写的。连最简单的servlet都会实
现connection pool。我老说过你很多次,没常识也要会掩饰,这样不是赤裸裸丢人吗?
https://github.com/TechEmpower/FrameworkBenchmarks/blob/master/servlet/src/
main/webapp... 阅读全帖
s*****n
发帖数: 2174
41
还有另一个办法取index, 就是利用 is.element()
比如
vec1 <- c(1,23,32,44,5,76,69,8)
vec2 <- c(2,4,6,7,8,9,1,3)
vec <- intersect(vec1, vec2)
is.element(vec1,vec)
[1] TRUE FALSE FALSE FALSE FALSE FALSE FALSE TRUE
得到原向量里面的哪些元素出现在intersect里面, 然后利用一个标准指标向量得到
index,
(1:length(vec1))[is.element(vec1,vec)]
这个方法和我之前说的有一点区别, 就在重复元素上. 我之前说的方法返回第一个
match的位置, 这个方法会给出所有match的位置.
M****o
发帖数: 7045
42
来自主题: _Inter版 - [翻译场] 2010-2011赛季战术回顾
原文 http://www.guardian.co.uk/football/blog/2011/jun/07/tactical-review-of-2010-11-season
日期 6月7日
媒体 卫报
作者 乔纳森•威尔森
译者注:false nine意谓回撤前锋。这类前锋活动范围经常在中前场,但经常回撤深至
中线,与10号并肩作战。在本文中,false nine就先暂且沿用英文原文,以待迪生。
标题:2010-2011赛季战术回顾
This was a season in which club football asserted its primacy, and the false
nine came from the periphery into the mainstream
这个赛季,滥觞已久的false nine逐渐汇入主流。
Barcelona's Lionel Messi wears No10 but has spearheaded the tactical vogue
for a false nine. Photograph: David Ramos/As... 阅读全帖
j***h
发帖数: 4412
43
Earthquake detection systems can sound the alarm in the moments before a
big tremor strikes—time enough to save lives
Japan’s system, which went live in 2007, makes heavy use of personal
technology. Alerts go out not only on television and radio but through
special receivers in homes, offices and schools. Pop-up windows on
computers show a real-time map with the epicenter’s location and the
radiating seismic waves. A timer counts down to the shaking at your
location and highlights predicted inte... 阅读全帖
r********y
发帖数: 2540
44
【 以下文字转载自 SanFrancisco 讨论区 】
发信人: laoguai (没开迷死吹的老怪), 信区: SanFrancisco
标 题: 湾区大新闻:核光大学CEO Jerry Wang 涉嫌VISA欺诈被逮捕起诉
发信站: BBS 未名空间站 (Sun Aug 5 12:02:53 2012, 美东)
http://www.mercurynews.com/peninsula/ci_21222408/sunnyvale-univ
15天内所有学生需要转学,15天后拿不出证据,学校关门。核光大学CEO同时也是国际
医药大学的CEO。
除VISA 欺诈,还有制造假文件,非法侵入政府电脑系统等其他罪名。
这个可是第二所中国人开的学校被查出VISA 诈欺了。 中文新闻里面好像都没提到。
。。。
Sunnyvale university CEO indicted on visa fraud charges
By Lisa M. Krieger and Molly Vorwerck
Staff writers
Posted: 08/02/2012 05:12:06 PM PD... 阅读全帖
b********n
发帖数: 38600
45
The Time Is Ripe For A False-Flag Attack On American Soil
Government engineered false-flag terrorism is a historically established
fact. For centuries, political and financial elites have been sinking ships,
setting buildings on fire, assassinating diplomats, overthrowing elected
leaders, and blowing people up, then blaming these disasters on convenient
scapegoats so that they can induce fear in the public and transfer more
power to themselves. Skeptics might argue whether certain calamities hav... 阅读全帖
h******n
发帖数: 674
46
一名华裔美籍女子因涉入2007年的一件国家安全信息走漏事件而被美国联邦法官剥夺美
国国籍。这名45岁李姓女子在2005年加入美籍,她名义上的假丈夫是中国公民持绿卡,
去年被驱逐出境。李姓女子是亚利桑反恐信息中心的合同工,负责头像识别技术。
Grace Li became a naturalized U.S. citizen in 2005. In 2009, she pleaded
guilty to knowingly making false statements in her pursuit of citizenship.
Credit: Courtesy of Grace Li
A federal judge in Arizona has ordered the U.S. government to revoke the
citizenship of a woman at the center of a 2007 security breach involving a
Chinese national who worked inside an Arizona intellige... 阅读全帖
b********n
发帖数: 38600
47
来自主题: Military版 - 25 Statist Propaganda Phrases
http://reece.liberty.me/2015/03/09/25-statist-propaganda-phrase
In the discourse of statists, there is a group of phrases of which one or
more tend to be present in nearly every argument.
While this is not an exhaustive listing of that group, it does contain
twenty-five of the most common phrases that statists use in their arguments.
As propaganda has a tendency to be repetitive, some of these phrases
contain the same logical fallacies, and will therefore have similar
refutations. As such, the p... 阅读全帖
m***n
发帖数: 12188
48
来自主题: Military版 - 关于虚假记忆
各位搜索一下 “recovered memory therapy”,曾经在美国流行,已经被禁止使用了
。 还有虚假记忆“false memory”,刚搜到一个极好的定义,忘记保存了。懒得再找
。大家自己看去。
注意,这句话是心理学专业协会的结论:
“Pseudomemories can be created of abuse events that never happened”
False memories of child abuse: late 1970s and the 1980s, 心理学带来了大量
false accusations of sexual abuse of children and women, 为什么呢?有人从社
会学上解释为这些妇女是在50-60年代长大的,60年代正是性解放的时代,所以她们的
父亲受到主流文化影响,施加性虐和恋童的概率特高。不过这个解释不靠谱。
正确的解释是,当时心理学家发明了recovered memory therapy, 一种新技术,政府大
力提倡,很多妇女主动或者被要求去参与,结果个个被发现小时候被abused,其技术本
质是一种... 阅读全帖
x*******6
发帖数: 994
49
Facial recognition failures in the UK prompt calls for a rethink of the
technology here
AM BY POLITICAL REPORTER TOM IGGULDEN ABOUT 10 HOURS AGO Email Facebook
Twitter WhatsApp Facial recognition technology used as airline passengers
arrive at a terminal. PHOTO Facial recognition technology is already being
used around the world. SUPPLIED A massive case of mistaken identity in the
UK is prompting calls for a rethink on plans to use facial recognition
technology to track down terrorists and traff... 阅读全帖
w********2
发帖数: 632
50
IPMI Authentication Bypass via Cipher 0
Dan Farmer identified a serious failing of the IPMI 2.0 specification,
namely that cipher type 0, an indicator that the client wants to use clear-
text authentication, actually allows access with any password. Cipher 0
issues were identified in HP, Dell, and Supermicro BMCs, with the issue
likely encompassing all IPMI 2.0 implementations. It is easy to identify
systems that have cipher 0 enabled using the ipmi_cipher_zero module in the
Metasploit Framework... 阅读全帖
首页 上页 1 2 3 4 5 6 7 8 9 10 下页 末页 (共10页)