I have used python to print a string "aaaaabbbbbccccc" into 5 separate columns of characters. I have not used an array to do this.
a a a a a
b b b b b
c c c c c
Now I want to print each column separately from each other, so for example print only the first column and then do this for all other columns:
a
b
c
To print the characters in 5 different columns I have used:
var="aaaaabbbbbccccc"
count=0
for char in var:
if count<4:
print(char, end=" ")
count=count+1
else:
count=0
print(char)
print('\n'.join(var[::5]))? Or evenprint(*var[::5], sep='\n'). For all columns -for i in range(5): print(*var[i::5], sep='\n')a b c a b c a b c ...in a vertical line?