I have the following code:
word = "Marble"
for char in word:
print char
The Output:
M
a
r
b
l
e
How can I make console print
Marble
I have the following code:
word = "Marble"
for char in word:
print char
The Output:
M
a
r
b
l
e
How can I make console print
Marble
To print the entire word, the for
loop is unnecessary.
Instead, use:
word = "Marble"
print word
Marble