Loops/N plus one half: Difference between revisions

Line 2,525:
[print(str(i+1) + ", ",end='') if i < 9 else print(i+1) for i in range(10)]
</syntaxhighlight>
 
{{works with|Python|3.x}}
<syntaxhighlight lang="python">n, i = 10, 1
while True:
print(i, end="")
i += 1
if i > n:
break
print(", ", end="")</syntaxhighlight>
 
=={{header|Quackery}}==
2,136

edits