user71388: https://www.instructables.com/Using-a-4-digit-7-segment-display-with-arduino/
I used this link to make my circuit and I used this code also but some numbers like 2,3 and 0 doesn't display correctly.

user2967: It looks like you have the center segment and the top left vertical segment reversed. For the image you show, if you switched the on/off states of those 2 segments, you'd see 1230.
I don't know if the problem is in your code or in your wiring. The simplest fix would be to swap the pins for those 2 segments.

71388: <p><a href="https://www.instructables.com/Using-a-4-digit-7-segment-display-with-arduino/" rel="nofollow noreferrer">https://www.instructables.com/Using-a-4-digit-7-segment-display-with-arduino/</a></p>
<p>I used this link to make my circuit and I used this code also but some numbers like 2,3 and 0 doesn't display correctly.<a href="https://i.stack.imgur.com/nWJVl.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/nWJVl.jpg" alt="(This is the error. First number is 1 second is 2 third is 3 and fourth is 0)" /></a></p>
 2967: <p>It looks like you have the center segment and the top left vertical segment reversed. For the image you show, if you switched the on/off states of those 2 segments, you'd see <code>1230</code>.</p>
<p>I don't know if the problem is in your code or in your wiring. The simplest fix would be to swap the pins for those 2 segments.</p>
