+ 1
I need help .
You need to make a program for a leaderboard. The program needs to output the numbers 1 to 9, each on a separate line, followed by a dot: 1. 2. 3. ... My attempt #your code goes here print(""" 1. 2. 3. 5. 6. 7. 8. 9. """ )
7 Respuestas
+ 1
you need to match the output just remove the extra spaces
print("""
1.
2.
3.
5.
6.
7.
8.
9.""")
or use
print("\n".join( str(i) + '.' for i in range(1,10)))
+ 3
n = int(input() or 10)
data = "sample"
for i in range(1, n):
print(f"{i}.", data)
+ 3
for num in range(1,10):
print("{}.".format(num))
+ 1
show your attempt
0
Print("1.\n2.\n3.\n4.\n5.\n6.\7.\n8.\n9.\n)
0
for( int i=1; i<=10;i++)
{ printf("%d \n",i);
}
- 1
List=[1,2,3,4,5,6,7,8,9]
For i in list:{
print(i,".\n ")
}