Using the stdout to debug print the solution in the leetcode con
- 时间:2020-09-07 12:03:44
- 分类:网络文摘
- 阅读:161 次
The leetcode web coding IDE has a premium debugger feature – however this is not enabled during the contest. Recently I found out that you can actually print to STDOUT and then when you run your solution – you will see the output – this is an easy yet powerful method to debug when you don’t have other better solutions.

leetcode-stdout-debugging-trick
This is a great way to debug your code when you don’t have a IDE at hand – sometimes I participated the weekly contests on iPad where I don’t have IDE and I don’t have access to the inbuilt leetcode debugger as well – in this case, the printing to stdout is the only practical way of debugging printing the variables. Prior to this, I can only change the code and return the variable as a debugging technique – which is very inefficient.

leetcode
–EOF (The Ultimate Computing & Technology Blog) —
推荐阅读:农夫山泉危机曝出饮用水行业乱象 消费者严重不信任国产奶粉的原因 国人消费崇洋媚外导致洋奶粉的傲慢 暴利诱惑导致贴牌洋奶粉占八成市场 食药监部门曝光12个保健食品违法广告 薏米红豆汤 如何烹饪果蔬食物营养损失更少 食品安全监管常态化胜过千句狠话 夏季凉拌西红柿时用蜂蜜更滋补 对大豆制品存在的一些认识误区
- 评论列表
-
- 添加评论