?? ch03.02.c
字號(hào):
// #include <iostream>
#include <iostream.h>
/**
** 2 raised to the power of 10: 1024
**/
int main()
{
int value = 2;
int pow = 10;
cout << value << " raised to the power of "
<< pow << ": \t";
int res = 1;
// loop control statement:
// repeat calculation of res
// until cnt is greater than pow
for ( int cnt=1; cnt <= pow; ++cnt )
res = res * value;
cout << res << endl;
}
?? 快捷鍵說(shuō)明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -