?? 6_61.cpp
字號:
#include <iostream>
#include <cstring>
using namespace std;
int main()
{ char *dictionary[][2] = //用指針數組定義小字典
{ "pencil", "A writing instrument.", "keyboard", "An input device.",
"rifle", "A sholder-fired firearm.", "airplane", "A fixed-wing aircraft.",
"network", "An interconnected group of computers.", "", ""
};
char word[80];
cout << "Enter word: "; cin >> word;
for(int i = 0; *dictionary[i][0]; i++)
if(!strcmp(dictionary[i][0], word))
{ cout << dictionary[i][1] << "\n"; break; }
if(!*dictionary[i][0]) cout << word << " not found.\n";
return 0;
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -