hi
I use LTspice but the code should work.
This is all you need:
<-----I had to put a blank line here for the code to work.
r1 1 2 10k
r2 2 3 5k
r3 3 4 4k
r4 4 0 3k
v1 1 0 dc 4 <---I renamed the voltage source for clairity
;.dc v1 4 4 1 <---don't need this because it defines a DC sweep
.op
;.print dc v(1,2) v(2,3) v(3,4) v(4) <--don't need this because .op prints out all voltage and currents.
Results from LTspice:
--- Operating Point ---
V(1): 4 voltage
V(2): 2.18182 voltage
V(3): 1.27273 voltage
V(4): 0.545455 voltage
I(R4): 0.000181818 device_current
I(R3): 0.000181818 device_current
I(R2): 0.000181818 device_current
I(R1): 0.000181818 device_current
I(V1): -0.000181818 device_current
eT