Dec-01-2019, 09:33 AM
Hi
Im trying to generate number sequence who i want to look like this.
But instead it looks like this.
Here is my code.
Im trying to generate number sequence who i want to look like this.
Quote:7-1-1234
8-2
9-3
10-4
11-5
12-6
13-7-1234
But instead it looks like this.
Quote:7-1-1234
13-7-1234
Here is my code.
value1 = (1234) value2 = (7) value3 = (7) for parts in range(value2): print(("{}-{}".format(value3 + parts, parts+1) + '-{}\n'.format(value1) if parts in [0, value2 - 1] else ''))What am i missing and doing wrong?