Ask Question
10 November, 09:04

Edhesive 3.5 Code Practice in Python answer

+3
Answers (1)
  1. 10 November, 09:17
    0
    This chapter is about variables in Python. So a variable can be any data type. And to find the datatype of a variable we need to use below code:

    x=10

    print (type (x))

    This will output: integer

    Now we can covert a string into integer as below:

    x=input ("Enter X:")

    But above x is considered as string, and we need to convert it to integer to make use in for loop or any calculation.

    we can use:

    int (x), and this will convert x to int from string.

    Also, we have operators to change the variable values like =. + =, - =, / =, * = etc. So you need to remember these, and you will be up with all that is required for understanding variables. And rest is self explanatory certainly.

    Explanation:

    The answer is self explanatory.
Know the Answer?
Not Sure About the Answer?
Get an answer to your question ✅ “Edhesive 3.5 Code Practice in Python answer ...” in 📙 Computers & Technology if there is no answer or all answers are wrong, use a search bar and try to find the answer among similar questions.
Search for Other Answers