Java Programming Quiz 4 Java Programming Quiz 4 A class declared as ‘final’ cannot be ……….a. compiledb. accessedc. inheritedd. initializedWe can compare one string with another by using ………. method.a. compareTo()b. compare()c. comapreWith()d. comapreBoth()A code of java to be run in webpage is called……….a. applicationb. appletc. jvmd. jreWhich of the following are jump statements?a. whileb. breakc. ford. ifIs this mandatory to mention the size of an array at the time of declaration?a. yesb. noWhich of the following is not access specifier in Java?a. publicb. privatec. protectedd. friendA class can have only one ……….a. constructorb. destructorc. main methodd. objectStrings are treated as ………. in Java.a. packageb. classc. objectd. variable………. method is used to remove leading and trailing whitespaces?a. trimString()b. trim()c. Trim()d. trimAll()Which of the following statements will execute the body of the loop at least once even if the condition is false?a. ifb. whilec. ford. do-while