Skip to content

Conversation

@prathamesh920
Copy link
Contributor

@prathamesh920 prathamesh920 commented Jun 12, 2020

While creating a C or CPP standard function based question,
the standard test case will simply be the assert function of CPP.
This replaces the writing of complete C code and print inputs and
expected output for the user code evaluation.
Now the creator simply needs to write the assert function.
Example: For add function (adding two numbers), the test case will be:

assert(add(1, 2) == 3)

closes #728

@pep8speaks
Copy link

pep8speaks commented Jun 12, 2020

Hello @prathamesh920! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻

Comment last updated at 2020-06-12 02:36:30 UTC

While creating a C or CPP standard function based question,
the standard test case will simply be the assert function of CPP.
This replaces the writing of complete C code and print inputs and
expected output for the user code evaluation.
Now the creator simply needs to write the assert function.
Example: For add function (adding two numbers), the test case will be:

assert(add(1, 2) == 3)
@prathamesh920 prathamesh920 force-pushed the c-cpp-assert-test-cases branch from 4eca5e0 to ac0c6bc Compare June 12, 2020 02:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Easy way to add code questions - C, C++

2 participants