00001
#include <iostream.h>
00002
#include <fstream.h>
00003
#include <string>
00004
#include <algorithm>
00005
#include <plearn/base/general.h>
00006
#include <plearn/base/stringutils.h>
00007
00008
using namespace PLearn;
00009
00010 int main(
int argc,
char** argv)
00011 {
00012
#ifdef USE_EXCEPTIONS
00013
try {
00014
#endif
00015
00016
bool skip_dot_info =
true;
00017
00018
string line;
00019
while (!cin.eof()) {
00020 getline(cin, line,
'\n');
00021
if (line ==
"")
00022
continue;
00023
vector<string> tokens =
split(line,
"/");
00024
if (tokens.size() == 2) {
00025
if ((skip_dot_info ==
false) || (tokens[0][0] !=
'.'))
00026 cout << tokens[0] <<
endl;
00027 }
else {
00028 cout <<
"..." <<
endl;
00029 }
00030 }
00031
#ifdef USE_EXCEPTIONS
00032
}
catch (
const PLearnError &e) {
00033 cout <<
"FATAL ERROR: " << e.message() <<
endl;
00034 }
00035
#endif
00036
return 0;
00037 }