1

I want to be able to scramble a word's letters, but i'm struggling to assign an input to a variable without returning an error

import random

Word = input("Input the value")

random.shuffle(Word)

print(Word)

If i leave the shuffle function in it returns an error saying:

TypeError: 'str' object does not support item assignment

How do i ask for an input that is assigned directly to a string for me to then scramble using this function? This is for Python 3.0 onwards

Aran-Fey
  • 39,665
  • 11
  • 104
  • 149
Ch0live
  • 13
  • 4

0 Answers0