-
-
Notifications
You must be signed in to change notification settings - Fork 128
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(mainwindow): use simplified instead of trimmed in diff #39
Conversation
Hi ouuan |
https://doc.qt.io/qt-5/qstring.html#simplified According to docs this function replaces
and
While this is obviously Wrong answer on Codeforces or any other platforms. Reverted the commit, Please open a new PR fixing this issue (We need to manually implement that function I talked about in #38) |
In other OJs this may be WA, but in most problems on CF, white spaces don't matter. |
Yes, So people who use Codechef and other platforms will complain about it. It will be better if newlines are maintained. |
Where should I write a function for comparing? It doesn't seem like a "member function". (In fact, almost all functions returns void.) |
Create a function with following signature in mainwindow.cc. bool MainWindow::isVerdictPass(QString output, QString expected){...}; It should return true if verdict is Then you need to declare it as well, in mainwindow.hpp, just after launchSession(); declare it (private); ....
bool isVerdictPass (QString, QString);
... Then replace that |
Yes they are member function that behave like callbacks, callbacks usually have void return type. They are normal C++ classes and functions. No magic, you can do whatever you like. |
This partially fixes #38.