Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Question 11: -- Consider the statements below: String a = JAVA: ; String b = How to ; String c = Program; Which of the

Question 11: -- Consider the statements below: String a = "JAVA: "; String b = "How to "; String c = "Program"; Which of the statements below will create the String r1 = "JAVA: How to Program"? String r1 = c.concat(b.concat(a)); String r1 = a.concat(b.concat(c)); String r1 = b.concat(c.concat(a)); String r1 = c.concat(c.concat(b)); Flag this Question

Question 12: -- Which of the following is not a method of class String? toUpperCase trim toCharacterArray All of the above are methods of class String Flag this Question

Question 13: -- StringBuilder objects can be used in place of String objects if ________. the string data is not constant the string data size may grow the programs frequently perform string concatenation All of the above. Flag this Question

Question 14: -- Given the following declaration: StringBuilder buf = new StringBuilder(); What is the capacity of buf? 0 10 16 20 Flag this Question

Question 15: -- Which of the following statements is true? The capacity of a StringBuilder is equal to its length The capacity of a StringBuilder cannot exceed its length. The length of a StringBuilder cannot exceed its capacity. Both a and b are true. Flag this Question

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Machine Learning And Knowledge Discovery In Databases European Conference Ecml Pkdd 2010 Barcelona Spain September 2010 Proceedings Part 2 Lnai 6322

Authors: Jose L. Balcazar ,Francesco Bonchi ,Aristides Gionis ,Michele Sebag

2010th Edition

364215882X, 978-3642158827

More Books

Students also viewed these Databases questions

Question

Why We Listen?

Answered: 1 week ago