I am not sure if this is a valuable tip, but I found it quite useful, so I am writing this with some courage. When you call ic(...) at the end of a Jupyter notebook cell, it repeats as shown below. This can sometimes cause confusion. Therefore, if you assign the last ic to a dummy variable (_), it will not repeat. Here is an example:
from icecream import ic
a, b,c = [1, 2, 3]
ic(a, b, c)
output:
ic| a: 1, b: 2, c: 3
(1, 2, 3)
Subtle Tip
from icecream import ic
a, b,c = [1, 2, 3]
_=ic(a, b, c)
I am not sure if this is a valuable tip, but I found it quite useful, so I am writing this with some courage. When you call
ic(...)
at the end of a Jupyter notebook cell, it repeats as shown below. This can sometimes cause confusion. Therefore, if you assign the last ic to a dummy variable (_), it will not repeat. Here is an example:output:
Subtle Tip
output: