Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <QtCore>
- int main(int argc, char **argv)
- {
- if (argc < 2)
- return 1;
- QFile file(QString::fromLocal8Bit(argv[1]));
- if (!file.open(QFile::ReadOnly))
- return 2;
- QRegExp rx("^Точка: (.*)$");
- foreach (const QString &line, QTextStream(&file).readAll().split("\r\n")) {
- if (rx.indexIn(line) >= 0)
- qDebug() << rx.cap(1);
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment