⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 10viii.cpp

📁 《C/C++程序设计导论(第二版)》一书的程序源文件
💻 CPP
字号:
// wordsort.cpp  Sort and output a list of 10 words from a list provided by
//    the user.
#include <iostream>
#include <fstream>
#include <string>using namespace std;const int SIZE =10;
void Sort (string[], int);

void main ()
{	string words[SIZE];
	int n;
	for (n=0; n<SIZE; n++)					// input the list of words
		cin >> words[n];

	Sort (words, SIZE);					// sort the list

	cout << "sorted words are:" << endl;
	for (n=0; n<SIZE; n++)					// output the list
		cout << words[n] << endl;
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -