0

Apologies for the mega noob question but I'm trying to create a string using a defined function with a variable for the parameter

def plusone(number):
    return (number + 1)

print('Enter a number')
Userinput = input()
print(' You have entered '+ str(plusone(Userinput)) + ' less 1')

I receive this error - TypeError: can only concatenate str (not "int") to str

Mturks83
  • 89
  • 2
  • 9

0 Answers0