topics

全部话题 - 话题: nbase
(共0页)
p***a
发帖数: 6202
1
版上多少兄弟玩nbase啊?觉得挺有意思的。
我刚注册了一个league,大家一起玩吧?人多热闹。
名字叫mitbbs
League ID:139224
password: yaoming
从这里加入:
http://nbase.nba.com/group/nba/myleagues
这个在线游戏模拟股票交易,每天买卖球员,组成自己的阵容,然后当天球员的比赛表
现(得分,助攻,篮板等,每一项都有打分)来确定你当天的得分,得分累计再参与联
盟里的排名。
具体规则见:
http://nbase.nba.com/group/main/home
h**i
发帖数: 712
2
来自主题: Linux版 - nbase是什么库
是啊,Linux下不太一样,直接在nbase下make没有目标,configure已经指定host和CC
,结果ld找不到库,nbase下的libnbase.a不知道为什么没识别。
w****x
发帖数: 2483
3
来自主题: JobHunting版 - 一道题
这题真TM坑爹啊~~
class node
{
int id;
int value;
int sum;
void send(int toId, int value);
int receive(int fromId);
void run()
{
int tmp = x;
int nLev = 0;
vector vec;
while (tmp%2 == 0)
{
int nRecv = x - (1 << nLev);
sum += receive(nRecv);
vec.push_back(nRecv);
nLev++;
}
if (id != n)
{
int nSend = min(id + (1 << nLev), n);
send(nSend, sum);
sum = receive(nSend);
}
else
... 阅读全帖
w****x
发帖数: 2483
4
来自主题: JobHunting版 - 一道题
这题真TM坑爹啊~~
class node
{
int id;
int value;
int sum;
void send(int toId, int value);
int receive(int fromId);
void run()
{
int tmp = x;
int nLev = 0;
vector vec;
while (tmp%2 == 0)
{
int nRecv = x - (1 << nLev);
sum += receive(nRecv);
vec.push_back(nRecv);
nLev++;
}
if (id != n)
{
int nSend = min(id + (1 << nLev), n);
send(nSend, sum);
sum = receive(nSend);
}
else
... 阅读全帖
w****x
发帖数: 2483
5
/*
Say you have an array for which the ith element is the price of a given
stock on day i.
Design an algorithm to find the maximum profit. You may complete as many
transactions as you like (ie, buy one and sell one share of the stock
multiple times). However, you may not engage in multiple transactions at the
same time (ie, you must sell the stock before you buy again).
*/
class Solution {
public:
int maxProfit(vector &a) {

int n = a.size();
int* rec = new int[n]... 阅读全帖
b*******h
发帖数: 53
6
这个dp算法有一个地方不懂:rec[j]是在第jth day卖出股票,这时的最大收益值。
这一块: int nBase = j-1 < 0 ? 0 : rec[j-1];
if (nBase + a[i] - a[j] > nMax)
nMax = nBase + a[i] - a[j];
为什么j-1th day卖出,一定要在jth day买入呢?有可能从j th day,股票一路下跌
,然后再长回来。

the
h**i
发帖数: 712
7
来自主题: Linux版 - nbase是什么库
交叉编译的时候报告 cannot find -lnbase
a******t
发帖数: 84
8
来自主题: Linux版 - nbase是什么库
nmap?
see this: http://goo.gl/CF32Gq
i***r
发帖数: 1035
9
来自主题: Programming版 - .mro是什么语言?
下面是一个简单的script 文件, 多谢:
@include "_bc_sort_stages.mro"
pipeline BC_SORT(
in bam input,
out bam bcsorted_bam,
)
{
call volatile BUCKET_BY_BC(
nbases = 2,
input = self.input,
)
call volatile BUCKET_BY_QNAME(
qnames = BUCKET_BY_BC.qnames,
input = BUCKET_BY_BC,
)
call volatile SORT_BY_BC(
bc_buckets = BUCKET_BY_BC.buckets,
non_bc_buckets = BUCKET_BY_QNAME.buckets,
)
return (
bcsorted_bam = SORT_BY_BC,
... 阅读全帖
(共0页)