Helps to debug leetcode
problems in IDE
- creating data structures such as
vector
,tree
andlist
. - Quickly print common containers
- Convert the input parameters of the Design problems into corresponding function calls.
boost-describe when debug design problems
- Create an array
Vec<int>
/Vec<string>
- Create a 2D array :
Vec2<int>
/Vec2<string>
- Create a linked list :
List()
- Create a tree :
Tree()
- Print
vector/string/map...
:D(name)
- Print
Tree/List/priority_queue
:name.print()
0.lintcode
/codewars
users need to replace {}
with []
and #
with null
1.Treat an array of parameters with multiple different types as an array of strings, and choose whether to convert to int according to whether it starts with ".
example:[[], ["leetcode"], [4], ["practice"], [3], [8], [10], [2], [6]]
in 2296
2.Treat n-ary-tree as graphs
3.if you are having problems with array subscript overflow, you can choose to turn on the (/fsanitize=address)
option in visual studio
and set the configuration to release
to get the same output as leetcode
,and get the actual line number of the code location where the error occurred.
1.add inliner
2.use std::setw(9)
,cout.width(9)
; to align the output to the right, which helps debug problems with grid
pprint
leetcode-helper
caide
boost.Describe
leetcode-playground-stringToString
For recursive problems, you may like it very much
there is a better one
1.online graph tools
https://csacademy.com/app/graph_editor/
https://silverfoxxxy.github.io/graph_editor/
2.Combinations Calculator (nCr)