Why does -- cycle not work in this CircuiTikz example? – tex.stackexchange.com

internet
I am trying to draw a simple closed loop using circuitikz. I noticed that using -- cycle does not work here (as shown in the figure on the right). Here is a minimal example: ...