S*A 发帖数: 7142 | 1 我一直拿不准你这个出的是什么情况。我没有用 Live 装 FC15,
都是 pre-upgrade 过来的。
改 windows default boot 非常容易。在 Grub 用 single user
mode 进入 command prompt. vi /etc/grub.conf.
你是用普通用户 login 么?
先试试用 text mode 启动然后再 startx? |
|
xt 发帖数: 17532 | 2 嗯,好在我备份了factory default.宏碁的机器 |
|
w*s 发帖数: 7227 | 3 i have 2 NICs in the pc,
so i manually edit /etc/network/interfaces,
e.g. make them both dhcp, 1 dhcp/1 static ...
every once a while i found 2 default gateway from "route" command,
1 for each NIC.
How to keep only 1 of them pls ? |
|
I*****y 发帖数: 602 | 4 2 default gateway有什么问题吗? |
|
|
b*s 发帖数: 82482 | 6 bash基本上已经稳坐第一把交椅了,基本上动摇不了了。就像是dvorak键盘虽然比
qwerty优越,但是人们已经习惯了qwerty,所以dvorak键盘只能是小众……
作为 interactive shell 的很好用,作为script interpreter 有些特性也简化了程式
,但是因为不是default 因此大部分script还是不要用zsh特性来写,只能用bash甚至
sh。不过目前写script的主流本来也不是shell script language了。
http://slopjong.de/2012/07/02/compatibility-between-zsh-and-bas |
|
G****n 发帖数: 618 | 7 Why does default exception use const char* instead of std::string
when defining the what() member function?
const char* const what() const;
I think the reason is to avoid dynamic memory allocation so no
additional exceptions are thrown, which might be caused by
the std::string class. |
|
P********e 发帖数: 2610 | 8 为什么最好不要用呢?
库函数这么多,没几个不用default argument |
|
n**d 发帖数: 9764 | 9 "You can provide default arguments for template parameters in class
templates, but not function templates."
the words are from "Thinking in C++" V2. The first part is easy understood,
which is something like this
template class Stack {...}
But how to understand the 2nd part, "not funtion templates". Is it something
like this, which should be illegal according to this rule?
template T sum(T* a) {...} |
|
k**f 发帖数: 372 | 10 The rule says you can have default *value* such as N=100 in template class,
but in template function you cannot do this. |
|
n**d 发帖数: 9764 | 11 My questionn is how to understand the "words" from the book. N=100 is about
the default parameter, but I don't think the "words" is talking about it. In
fact, you can not have (int N) as function template parameter.
, |
|
r****t 发帖数: 10904 | 12 g++ 搞来搞去,最后还是用了 overloading 了事。 这里的 default argument 完全搞
不懂是在干什么。。。
现在老这么 try and error, 摸石头过河,太惨了。 |
|
a********r 发帖数: 58 | 13 Why default linkage is static for const global variable in C++, but extern
in C? Thanks! |
|
t****t 发帖数: 6806 | 14 default initialization for int is zero-initialization. (8.5, 5) |
|
c***a 发帖数: 84 | 15 Default initialization of a POD object is zero initialization [§8.5, ¶
5]. |
|
c***a 发帖数: 84 | 16 Wow. The language is getting more complicated every day. The terms are
confusing enough already. Their meanings even change over time!
Now back to OP's question. This is also a question for both thrust and
randomtiger: What is the value of "int()"?
My understanding is that this means a value-initialization (or default-
initialization in the old days), so its value is 0. Therefore, the
vector array must be initialized to 0's. This result actually has
nothing to do with the behavior of current def |
|
g****i 发帖数: 100 | 17 The C header file uses some special symbols defined in Windows English
1252. I am unable to compile them if I set the system language Uni-code to
Chinese (Code page 936).
I don't want to switch the system language often since it requires reboot.
Is there any way to configure the Visual Studio defaulting to code page
1252?
This problem has been bothering me for years.
Thanks for the ideas. |
|
o**********a 发帖数: 330 | 18 class A {
public:
A(const int, const vector&);
A(const A&);
virtual A& operator=(const A&);
//...
protected:
int i;
vector s;
};
A::A(const int a,const vector& b):i(a),s(b){}
//我这么写没有定义defualt constructor,请问如何定义这个constructor
//另外,一般写类的时候,是不是最好都定义default contructor |
|
n*******r 发帖数: 22 | 19 【 以下文字转载自 JobHunting 讨论区 】
发信人: newdriver (小小的光), 信区: JobHunting
标 题: 问一个C++问题:default parameter and overriding/inheritanc
发信站: BBS 未名空间站 (Tue Feb 22 01:33:31 2011, 美东)
class A
{
private:
int n;
public:
virtual void Fun1(int no=10)
{
n = no;
cout<<"A::Fun1"<
}
};
class B : public A
{
private:
int m;
public:
virtual void Fun1(int no=20)
{
m = no;
cout<<"B::Fun1()"<
}
}
int main()
{
B b;
A &a =b;
a.Fun1();
return 0;
}
这个程序的输出是 B::Func1()10
实在想不明白为什么输出... 阅读全帖 |
|
z****e 发帖数: 2024 | 20 default parameters are statically bound. |
|
g*********s 发帖数: 1782 | 21 the following code reads lines from the input file and skip the empty lines.
how to change the following code such that if argv[1] is not provided, we
use cin as default ifstream?
int main() {
vector lines;
ifstream input_file(argv[1]);
if ( input_file.is_open()) {
while ( !input_file.eof() ) {
string str;
getline(input_file, str);
if ( str.empty() ) {
continue;
}
else
{
... 阅读全帖 |
|
G****A 发帖数: 4160 | 22 The question is inspired by Item 38 in <>. Given
following code,
*****************
enum ShapeColor { RED, GREEN, BLUE };
class Shape {
public:
virtual void draw(ShapeColor color = RED) const = 0;
...
};
class Rectangle: public Shape {
public:
//definition of draw() goes here.
...
};
********************
How to define the draw() in Rectangle so that it comes with a default
parameter value other than RED?
NOTE: the article did mention that a definition like this will not wor... 阅读全帖 |
|
s*****e 发帖数: 33 | 23 Is there any difference between the following two implementations?
struct Foo
{
enum Enum
{
SIZE = 1024;
}
char m_buf[SIZE];
};
struct Foo
{
Foo()
{}
~Foo()
{}
enum Enum
{
SIZE = 1024;
}
char m_buf[SIZE];
};
You may get some surprise under gcc 3.4 or 4.1, see more detail:
http://streetprogrammer.blogspot.com/2011/12/default-constructo |
|
vi 发帖数: 309 | 24 奇怪的问题,谁帮忙看一下,谢谢!
int main()
{
int arr[] = {1, 2, 3, 4, 5, 6, 7, 8, 9};
list tlist(arr, arr+(sizeof(arr)/sizeof(int)));
int psum;
for_each(tlist.begin(), tlist.end(), [&psum](int &_val) {
_val += psum;
psum = _val;
});
for (auto _val: tlist) { cout << _val << " "; };
cout << endl;
cout << *(tlist.begin());
}
g++ default:
$2 4 7 11 16 22 29 37 46
2$
if compile with -O1 then it will produce the correct output:
$1 3 6 10 15 21 28 36 45
1$ |
|
f*z 发帖数: 421 | 25 大牛,同学们,请教,static member method 可不可用default argument?比如,
enum Index
{
INDEX_A = 0,
INDEX_B
};
class foo
{
public:
static void method1( int a, int b = Index::INDEX_A);
};
编译可以过,但有什么要注意的地方?
多谢! |
|
m*********a 发帖数: 3299 | 26 你用的是那个版本的IDE,我用的是Code::Blocks
int b=Index::INDEX_A 或int b=Index.INDEX_A无法通过编译
只能用 int b=INDEX_A 或 Index b=INDEX_A;
太落后了。
而且enum 在C++是个class么?INDEX_A 的default value 是0,INDEX_B是1. |
|
w*s 发帖数: 7227 | 27 In my server.js, i have this
app.get('/', function(req, res)
{
res.sendfile(path.resolve('../client/login.html'));
});
restart "node server.js", my webpage still displays ../client/index.html
directly by default.
What am i missing here ?
Thanks ! |
|
t*m 发帖数: 4414 | 28 I am using Windows XP.
One day I visited Sina.com (regreting)
and the IE default home page has been set as
http://vs.6h.com.cn/?ID=247939146&AG=0,
which leads me to www.sina.com.cn
I cannot correct it from the "internet Options",
I guess they have modified my registry.
Too bad.
Can you help me out?
Thank you very much. |
|
j****z 发帖数: 1 | 29
add this line to stdio.h or windows.h
#pragma comment(lib,"xxx.lib")
and make sure link with default library is checked. |
|
T*******x 发帖数: 8565 | 30 我已经把firefox设成default browser了,但是用Google desktop gadget
看新闻的时候,每次都是启动IE,这个在哪里改啊? |
|
T*******x 发帖数: 8565 | 31 我用Windows XP,default browser设为Firefox,
但是从其他应用程序启动browser的时候,经常不是启动firefox,而是IE/Maxthon,
比如我的MSN Messenger如果检测到有新的email,点击启动的是IE/Maxthon,
我的google gadget,news,我点击阅览,启动的也是IE/Maxthon,
我希望启动的是firefox,请问这个在哪里改?是在regedit里吗?怎么改?谢谢。 |
|
T*******x 发帖数: 8565 | 32 我在IE/Maxthon里面都取消了“check if IE/Maxthon is default browser”,
还是不行。好吧。谢谢。 |
|
l******d 发帖数: 1633 | 33 嗯,messenger那个是肯定没戏
default browser那个有时候会出问题,俺记得好像是删了注册表里一个啥
东西,然后让firefox check了一下就好了 |
|
c*******o 发帖数: 1722 | 34 say, after pdflatex for a beamer file, i want the presentation
opens up full screen at default? anyway to achieve that?
thanks |
|
s***w 发帖数: 521 | 35 what is the default font setup of latex2e, if no specification/usepackage?
thanks! |
|
s***w 发帖数: 521 | 36 If I use winedt5.4 on win xp, push latex, and dvi2pdf button to generate the
pdf, the default font is still computer modern roman?
thanks! |
|
v****m 发帖数: 26 | 37 In our sgi origin system, we need use NQS' command "qsub" to submit jobs. I
want to know what's the default resouce limit such as stack size, cpu time,
etc., for the queque job. Thanks for the help. |
|
B*******e 发帖数: 3882 | 38 How to Change Windows Explorer Default View to My Computer |
|
k**e 发帖数: 86 | 39 i know how to set the default langauge for the selected text, but do not know
how to do for the whole PPT file (especially for spelling check). Any
suggestion is very appreciated. |
|
k**e 发帖数: 86 | 40 I tried, but it did not work.
Enabled languages: Chinese (Simplified), English (U.S.)
Default version of Microsoft Office: English (U.S.) |
|
f****g 发帖数: 2 | 41
我刚装了IE7,奇怪的是,default search engine 是google. 我还以为ms 和google达
成什么协议了呢。 不知是什么原因 |
|
j******a 发帖数: 1599 | 42 【 以下文字转载自 Hardware 讨论区 】
发信人: jiamajia (其实我特讨厌高丽棒子), 信区: Hardware
标 题: 问各位一个default program的问题
发信站: BBS 未名空间站 (Mon Jun 18 21:41:47 2007)
电脑上的USB drive不知道怎么弄得选择成用某个office的程序缺省打开.后来把office
uninstall了,可以每次插上这个jump drive还是要找这个程序, 然后抱错说找不到,双
击左键也是这样,右键可以看见黑体的缺省程序还是这个.
我想问,怎样才能够改回双击就能够打开文件夹的模式,是不是要改注册表的某个地方?
系统是Win XP Pro |
|
s***i 发帖数: 49 | 43 是不是经济差,这些买主付不出钱,只能default? |
|
l******n 发帖数: 213 | 44 A Quantitative Theory of Unsecured Consumer Credit with Risk of Default |
|
U*****e 发帖数: 2882 | 45 ......
I am not sure what you mean. CAPM is about market risk premium, it says
nothing about default risk premium. |
|