user11879188
user11879188

Reputation:

How to add the value of two variables together

I have two variables and I want to add there values together, the variables munt be added like math because the variables are DF = ("374") AND DG = (INPUTLENGTH)… can I do it like this...

MyVariable = MyVariable + MyOtherVariable

Upvotes: 0

Views: 51

Answers (1)

clubby789
clubby789

Reputation: 2733

variable = int(df) + dg

You have to convert df, a string, to an integer, so it can be added to the other integer.

Upvotes: 2

Related Questions