Skip to content

Commit

Permalink
Update Readme.md
Browse files Browse the repository at this point in the history
  • Loading branch information
dv-rastogi authored Nov 1, 2020
1 parent 7f82321 commit 23488ed
Showing 1 changed file with 15 additions and 5 deletions.
20 changes: 15 additions & 5 deletions Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,20 +8,30 @@ For optimization problems sometimes your optimized code tends to fail on corner

To overcome such annoying issues of brainstorming the aforementioned corner cases yourself, the naive idea of stress testing comes into play.

For the very same problem, you quickly code out a brute solution and hopefully with the help of my script :ok_man: and a random case generator (User parameter) and *voilà*, you get the test case your code was failing on!
For the very same problem, you quickly code out a brute solution and hopefully with the help of my script :ok_man: and a random case generator (User parameter), you compare your output against the brute output (User parameter) and hope for a **fail verdict** and *voilà*, you get the test case your code was failing on!


#### Please refer *stressCheck.py* for modelling required user parameters!

Currently configured for [Combination lock - Google kickstart round G](https://codingcompetitions.withgoogle.com/kickstart/round/00000000001a0069/0000000000414a24)

## Preview

![OK verdicts](img/1.png)

![Fail verdicts](img/2.png)

## How to use
* Code an optimized solution for the problem. *In my repo, it's "T.cpp"*
* Code a brute solution for the problem. *In my repo, it's "brute.cpp"*
* Ensure both your brute & optimized programs recieve input from a file. *In my repo, it's "inputf.in"*
* Update *gen* function in *stressCheck.py* in order to randomly generate your test cases.
* Update *checker* function in *stressCheck.py* in order to form basis of comparison for your response and brute response. *In my repo, it's string comparison*
* Wait to hopefully retrieve a corner case, lol.

```
Currently supported on Linux/Mac
```

## Preview

[OK verdicts]

#### All contributions are welcomed! :hand:

0 comments on commit 23488ed

Please sign in to comment.