I made a type() function which functions similarly to print except it types character by character. The problem is, when I try to implement multiple str arguments it just prints everything at once.
The code I used originally was:
import sys
import time
def type(text):
for char in text:
sys.stdout.write(char)
sys.stdout.flush()
time.sleep(0.05)
print()
In order to add more str arguments, I did:
import sys
import time
def type(*text):
for char in text:
sys.stdout.write(char)
sys.stdout.flush()
time.sleep(0.05)
print()
In practice, however, it usually just prints everything at once, like a normal print function. Any pointers?