This is your Competitive Companion, with this extension you can make test cases for your cpp file, run any files on them and see the result of your submission.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
This is your Competitive Companion, with this extension you can make test cases for your cpp file, run any files on them, see the result of your submission, make test cases for your custom test case generator.
Happy rating to you all.
How to make test cases
1.> Make Test cases
Make your solution.cpp file and take input via 'cin' .
Specify limits in comments for each variable after cin (in same line).
Seperate upper and lower limits via '-'
You can give multiple limits of different viariables seprated by spaces(' ').
for example "cin>>a;//1-15".
for example "cin>>b>>c;//1-15 2-20".
2.> Specify Time limit and number of test cases to be made
Make an extra commented line at the end of the code.
Specify Timeout and number of test cases to be made.
Specify each value via '-'.
Seperate items via spaces.
for example "//timeout-2000 num-5"
num represented number of test cases to be formed
If you dont specify timeout then by default it set to "2000" milliseconds.
3.> Running test on a file
Make an extra commented line at the end of the code.
Specify Timeout and filename(if running tests).
Specify each value via '-'.
Seperate items via spaces.
for example "//timeout-2000 test-in00.txt"
test represented filename of the test case
If you dont specify test then by default it set to "all".
If you dont specify timeout then by default it set to "2000" milliseconds.
4.> Making test case from a different file
This step is same as of 2.
Requirements
Cpp compiler is required for the extension to work