Solved

Which of the Following Statements Converts a String Object Variable

Question 46

Multiple Choice

Which of the following statements converts a String object variable named str to an int and stores the value in the variable x?


A) int x = Integer.integer(str) ;
B) int x - str;
C) int x = Integer.parseInteger(str) ;
D) int x = Integer.parseInt(str) ;

Correct Answer:

verifed

Verified

Unlock this answer now
Get Access to more Verified Answers free of charge

Related Questions