avatar
Priint .chm file (转载)# Software - 软件世界
s*o
1
为自己找暑期工挣生活费。femail,在校graduate student.会烧家常菜(同学中口碑很
好),会煲汤和糖水,会做一般家务,很爱清洁。求职做住家baby-sitter,月子保姆,
或者家教(在houston 或cinncinati可以通勤)。
我很勤快,很好沟通,希望雇主您也是通情达理,好相处的人。
联系方式:s********[email protected] 如果沟通后条件适宜,我会跟您视频联系。
非诚勿扰,谢谢。
avatar
z*t
2
技术孵化?还是RESEARCH???
avatar
a*a
3
从外部输入时是使用str输入。输入以后想计算,所以想换回float类型。如何写?
avatar
i*p
4
【 以下文字转载自 JobHunting 讨论区 】
发信人: isup (No), 信区: JobHunting
标 题: Priint .chm file
发信站: BBS 未名空间站 (Sat Mar 15 23:54:55 2008)
Does anyone know how to print the whole book on time? Not want to print one
topic by one topic.
Thanks!
avatar
a*l
5
research. got offer?

【在 z********t 的大作中提到】
: 技术孵化?还是RESEARCH???
avatar
T*i
6
stringstream

【在 a***a 的大作中提到】
: 从外部输入时是使用str输入。输入以后想计算,所以想换回float类型。如何写?
avatar
x*r
7
I heard that no research, R& D only

【在 z********t 的大作中提到】
: 技术孵化?还是RESEARCH???
avatar
T*9
8
string s;
float f;
stringstream ss;
ss << s;
ss >> f;

【在 a***a 的大作中提到】
: 从外部输入时是使用str输入。输入以后想计算,所以想换回float类型。如何写?
avatar
a*l
9
this is a little bit confusing... I suppose R&D means "research and
development"?

【在 x******r 的大作中提到】
: I heard that no research, R& D only
avatar
a*a
10
3x a lot!!!

【在 T*****9 的大作中提到】
: string s;
: float f;
: stringstream ss;
: ss << s;
: ss >> f;

avatar
x*r
11
I mean that no pure research exists like Microsoft research & IBM research.

【在 a****l 的大作中提到】
: this is a little bit confusing... I suppose R&D means "research and
: development"?

avatar
T*i
12
靠,俺先说的

【在 a***a 的大作中提到】
: 3x a lot!!!
avatar
m*i
13
能给俺讲讲architecture/compiler中啥叫做pure research吗?
avatar
a*a
14
两个都谢谢!

【在 T*******i 的大作中提到】
: stringstream
avatar
f*1
15
research,你要干啥?

【在 z********t 的大作中提到】
: 技术孵化?还是RESEARCH???
avatar
f*y
16
atof 在C++里不常用吗?
avatar
z*t
17
汗,几天没上来了,不好意思,就帮朋友问下而已,一哥们儿工作了几年想往那里跳。
。。貌似按大家的说法,不大行得通,
avatar
a*a
18
新手。。。学了没几天。。。网上查到有用这个的。。

【在 f******y 的大作中提到】
: atof 在C++里不常用吗?
avatar
m*t
19
我一朋友刚拒了intel去sohu

【在 z********t 的大作中提到】
: 汗,几天没上来了,不好意思,就帮朋友问下而已,一哥们儿工作了几年想往那里跳。
: 。。貌似按大家的说法,不大行得通,

avatar
p*o
20
I always use that, why bother to use xxxxstream ...

【在 f******y 的大作中提到】
: atof 在C++里不常用吗?
avatar
d*e
21
... ...Sohu不比Intel还糗。你朋友过去直接作VP?

【在 m****t 的大作中提到】
: 我一朋友刚拒了intel去sohu
avatar
f*y
22
hehe, i always use that too. But it seems C++ prefer xxxxstream. I guess it
is just like printf and cout.
avatar
m*t
23
senior吧
不过听他说原因是sohu多给了6w rmb

【在 d******e 的大作中提到】
: ... ...Sohu不比Intel还糗。你朋友过去直接作VP?
avatar
p*o
24
There is no such preference as far as I know.
I usually found printf is more readable than cout.

it

【在 f******y 的大作中提到】
: hehe, i always use that too. But it seems C++ prefer xxxxstream. I guess it
: is just like printf and cout.

avatar
f*1
25
想不到

【在 m****t 的大作中提到】
: senior吧
: 不过听他说原因是sohu多给了6w rmb

avatar
r*o
26
stringstream is dealing with strings, and string is more convenient than
char,

【在 p***o 的大作中提到】
: I always use that, why bother to use xxxxstream ...
avatar
d*e
27
6W是一个很大的比例?做Senior给多少啊?
要是我20W去Intel,26W去Sohu,我估计会选择Intel.

【在 m****t 的大作中提到】
: senior吧
: 不过听他说原因是sohu多给了6w rmb

avatar
p*o
28
You don't get it. Convert std::string to const char * is just one function
call. atof is the other and that's all.
Why bother to create/name an xxxxstream object, send in the string and
call the overloaded operator >>?

【在 r****o 的大作中提到】
: stringstream is dealing with strings, and string is more convenient than
: char,

avatar
m*t
29
各-2w
我觉得对于一个30岁的写软件的,intel和sohu的差别不如几w块钱

【在 d******e 的大作中提到】
: 6W是一个很大的比例?做Senior给多少啊?
: 要是我20W去Intel,26W去Sohu,我估计会选择Intel.

avatar
t*t
30
if you know you have char* and you want to double, then it is easier to use
atof
but stream works with template. e.g. you may say
template
void convert_to_whatever(const string& s, T& value)
{
istringstream iss(s);
iss>>value;
}
a good programmer can choose whatever tool that best fits the situation.

【在 p***o 的大作中提到】
: You don't get it. Convert std::string to const char * is just one function
: call. atof is the other and that's all.
: Why bother to create/name an xxxxstream object, send in the string and
: call the overloaded operator >>?

avatar
z*t
31
那再向大家打听一下,这个公司具体是做哪方面的,具体点说就是
1。研究开发什么的?我知道他好像做很多系统底层的东西,而且听说现在搞这个开源
的移动平台比较多,其他还做不做什么,比如COMPILER?
2。另外他这种研究是指纯粹基于产品的研究,还是像MSRA那种,就是发文章的研究。
。。
3。我朋友本科,工作4年,应该达到了小牛的水准(大牛不敢说,实在不知道大牛的具
体定义),做系统底层,例如驱动和板极支持包,属于纯程序员类的,进这个地方有多
大困困难,
avatar
p*o
32
Yeah, but hardly to believe a guy knows how to write convert_to_whatever
will ask that question. And I would specialize the template to use atof
for double (need to change your design though).

use

【在 t****t 的大作中提到】
: if you know you have char* and you want to double, then it is easier to use
: atof
: but stream works with template. e.g. you may say
: template
: void convert_to_whatever(const string& s, T& value)
: {
: istringstream iss(s);
: iss>>value;
: }
: a good programmer can choose whatever tool that best fits the situation.

avatar
m*t
33
没多大困难,只要水平还行,里面有人可以推荐你拿到面试

【在 z********t 的大作中提到】
: 那再向大家打听一下,这个公司具体是做哪方面的,具体点说就是
: 1。研究开发什么的?我知道他好像做很多系统底层的东西,而且听说现在搞这个开源
: 的移动平台比较多,其他还做不做什么,比如COMPILER?
: 2。另外他这种研究是指纯粹基于产品的研究,还是像MSRA那种,就是发文章的研究。
: 。。
: 3。我朋友本科,工作4年,应该达到了小牛的水准(大牛不敢说,实在不知道大牛的具
: 体定义),做系统底层,例如驱动和板极支持包,属于纯程序员类的,进这个地方有多
: 大困困难,

avatar
r*y
34
atof has its limitations:
http://www.cplusplus.com/reference/clibrary/cstdlib/atof.html
double atof ( const char * str );
Return Value
On success, the function returns the converted floating point number as a
double value.
If no valid conversion could be performed, or if the correct value would
cause underflow, a zero value (0.0) is returned.
If the correct value is out of the range of representable values, a positive
or negative HUGE_VAL is returned.

【在 p***o 的大作中提到】
: Yeah, but hardly to believe a guy knows how to write convert_to_whatever
: will ask that question. And I would specialize the template to use atof
: for double (need to change your design though).
:
: use

avatar
x*r
35
I have mentioned before that this lab do not do pure research.
If you like pure research, you should apply Intel research instead of this
one.

【在 z********t 的大作中提到】
: 那再向大家打听一下,这个公司具体是做哪方面的,具体点说就是
: 1。研究开发什么的?我知道他好像做很多系统底层的东西,而且听说现在搞这个开源
: 的移动平台比较多,其他还做不做什么,比如COMPILER?
: 2。另外他这种研究是指纯粹基于产品的研究,还是像MSRA那种,就是发文章的研究。
: 。。
: 3。我朋友本科,工作4年,应该达到了小牛的水准(大牛不敢说,实在不知道大牛的具
: 体定义),做系统底层,例如驱动和板极支持包,属于纯程序员类的,进这个地方有多
: 大困困难,

avatar
w*g
36
C++ is going to be dead if converting from string to float takes this effort
. This is obviously not simple enough to be a good method.

【在 T*****9 的大作中提到】
: string s;
: float f;
: stringstream ss;
: ss << s;
: ss >> f;

avatar
m*i
37
人家本来就不是要去做pure research。
再者说你怎么定义pure research? 尤其在体系结构和compiler这一领域。
avatar
h*e
38
Please differentiate between a language and a library.

effort

【在 w***g 的大作中提到】
: C++ is going to be dead if converting from string to float takes this effort
: . This is obviously not simple enough to be a good method.

avatar
m*i
39
我选sohu,呵呵

【在 d******e 的大作中提到】
: 6W是一个很大的比例?做Senior给多少啊?
: 要是我20W去Intel,26W去Sohu,我估计会选择Intel.

avatar
n*e
40
这也太麻烦了吧?
有没有更快的方法?

【在 T*****9 的大作中提到】
: string s;
: float f;
: stringstream ss;
: ss << s;
: ss >> f;

avatar
r*r
41
可以用boost 的 lexical_cast("12.34").
它内部用stringstream 和 <> 实现。
avatar
r*r
42
what do u mean?
avatar
n*e
43
虽然你调用了一个已有的function, 但是那个function本身绕道太远。

【在 r*********r 的大作中提到】
: what do u mean?
avatar
r*r
44
well, you have to put the usage in the right context.
if you are parsing millions of strings into floats (maybe
in high throughput networking environment?), then yeah,
atof or sscanf run much faster.
if you are only parsing the user input in an interactive
environment, why do you even care the complexity of the function
call?
avatar
n*e
45
I agree.

【在 r*********r 的大作中提到】
: well, you have to put the usage in the right context.
: if you are parsing millions of strings into floats (maybe
: in high throughput networking environment?), then yeah,
: atof or sscanf run much faster.
: if you are only parsing the user input in an interactive
: environment, why do you even care the complexity of the function
: call?

avatar
r*r
46
这些function的适用性和性能成反比。
atof 只能用在 float/double。
sscanf 只能用在 integer, float.
lexical_cast 则可以使用在任何有operator>>定义的类型。
从性能上看,我猜的是 sscanf 比 lexical_cast 快5到10倍。
atof 又比 sscanf 快5倍左右。
还有,sscanf 是最容易用错的一个函数,对初学者简直是噩梦。
avatar
w*g
47
请展开说说sscanf有什么要注意的。我用这个函数很多,但是因为写的不是什么正经程
序,所以一直没出过问题。

【在 r*********r 的大作中提到】
: 这些function的适用性和性能成反比。
: atof 只能用在 float/double。
: sscanf 只能用在 integer, float.
: lexical_cast 则可以使用在任何有operator>>定义的类型。
: 从性能上看,我猜的是 sscanf 比 lexical_cast 快5到10倍。
: atof 又比 sscanf 快5倍左右。
: 还有,sscanf 是最容易用错的一个函数,对初学者简直是噩梦。

avatar
r*r
48
the signature of sscanf is:
int sscanf(const char *, const char *,...)
the arguments are supposed to be passed by their address,
but most beginners often forget to use the "&" operator.
the compiler won't complain since there's no type checking at all.
running the executable will cause a segmentation fault.
another funny fact is that if you switch the string to be scanned
and the format string, it still runs! like the following:
float x = 4.3;
...
sscanf("%f", "12.34", &x);
the x will still be 4
avatar
c*t
49
beginner...什么事情到了 beginner 的手里都有可能发生。。。
gcc 的 -Wall warning 对 printf, scanf 都很管用。
另外 sscanf 不是还有个 return value 你怎么不查一下。里面告诉你
有几个成功 assign 的。

【在 r*********r 的大作中提到】
: the signature of sscanf is:
: int sscanf(const char *, const char *,...)
: the arguments are supposed to be passed by their address,
: but most beginners often forget to use the "&" operator.
: the compiler won't complain since there's no type checking at all.
: running the executable will cause a segmentation fault.
: another funny fact is that if you switch the string to be scanned
: and the format string, it still runs! like the following:
: float x = 4.3;
: ...

avatar
r*r
50
ft, 谁不是从 beginner 过来的。。。
我记得以前就经常忘了用&.
那时候用turbo c, 不记得有没有类似 -Wall 的东西。

【在 c*****t 的大作中提到】
: beginner...什么事情到了 beginner 的手里都有可能发生。。。
: gcc 的 -Wall warning 对 printf, scanf 都很管用。
: 另外 sscanf 不是还有个 return value 你怎么不查一下。里面告诉你
: 有几个成功 assign 的。

avatar
r*r
51
现在的c++初学者,根本没必要去折腾那些c的库函数。
甚至连指针也可以放到最后再学。否则cs101 只会被java占据。
avatar
t*t
52
怎么能拿早年间东西的标准来要求现在的编译器.

【在 r*********r 的大作中提到】
: ft, 谁不是从 beginner 过来的。。。
: 我记得以前就经常忘了用&.
: 那时候用turbo c, 不记得有没有类似 -Wall 的东西。

avatar
r*r
53
cpu 和 内存都涨了 1000 倍不止。
编程工具(compiler,library,debugger etc)进步很小,
感觉有新意的就只是stl和boost的一些东西。
avatar
m*e
54
no pointer? then you'd better just learn java instead

【在 r*********r 的大作中提到】
: 现在的c++初学者,根本没必要去折腾那些c的库函数。
: 甚至连指针也可以放到最后再学。否则cs101 只会被java占据。

avatar
r*r
55
the error condition checking of c functions is so inconsistent.
in the case of atoi, atof, a return value of 0 simply doesn't tell whether
there is an scanning error or a 0 is correctly scanned.

【在 c*****t 的大作中提到】
: beginner...什么事情到了 beginner 的手里都有可能发生。。。
: gcc 的 -Wall warning 对 printf, scanf 都很管用。
: 另外 sscanf 不是还有个 return value 你怎么不查一下。里面告诉你
: 有几个成功 assign 的。

相关阅读
logo
联系我们隐私协议©2024 redian.news
Redian新闻
Redian.news刊载任何文章,不代表同意其说法或描述,仅为提供更多信息,也不构成任何建议。文章信息的合法性及真实性由其作者负责,与Redian.news及其运营公司无关。欢迎投稿,如发现稿件侵权,或作者不愿在本网发表文章,请版权拥有者通知本网处理。