Question: what is the output? public class Test1{ public static void main(String[] args) { String[] a = {TRUE, FALSE); swap(a); System.out.println(a[0] = + a[0] +
public class Test1{ public static void main(String[] args) { String[] a = {"TRUE", "FALSE"); swap(a); System.out.println("a[0] = " + a[0] + " a[1] = " + a[1]); public static void swap(String [] a) { String temp = a[0]; a[0] = a[1]; a[1] = temp
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
