115k views
1 vote
What kind of variable will be created by a line of code that reads num1 = int(input("Please enter your favorite number.")) ? Group of answer choices a string a float an integer a generic

User Amdn
by
4.7k points

2 Answers

3 votes

Answer:

Its an integer ⌐■_■

User Kamui
by
5.3k points
2 votes

Answer:

An integer

Step-by-step explanation:

Given

num1 = int(input("Please enter your favorite number."))

Required

The variable type

In Python, when an input is gotten through

var-name = data-type(input(Prompt))

The variable var-name assumes the datatype data-type

This implies that:

num1 = int(input("Please enter your favorite number."))

num1 will assume integer datatype

User Abir Chokraborty
by
5.0k points