Question: Consider the following methods. public void modParams ( int x , String s 1 , String s 2 ) { x + + ; s

Consider the following methods.
public void modParams(int x, String s1, String s2){
x++;
s1=s1+BB;
s2= new String(memory);
}
public void print()
{
int k=1;
String s1="AA";
String s2= "space";
modParams(k, s1, s2);
}
System.out.println(k +""+ s1+""+s2);
a.1 AA space
b.1 AABB space
c.1 AABB memory
d.2 AABB space
e.2 AABB memory
 Consider the following methods. public void modParams(int x, String s1, String

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!