0

what is the type of this statement??? String a=new String("1"); if it is wrong statement.plz be kind to correct it.im a beginner

26th Sep 2016, 7:33 PM
Dinuka
4 Antworten
+ 3
It's a declaration of a String variable named a, and assignment of the string "1" (created dynamically) to it.
26th Sep 2016, 8:01 PM
Zen
Zen - avatar
+ 1
@praveen as far it contains double quotes the system sees it as a string
26th Sep 2016, 8:06 PM
jerry
jerry - avatar
0
got it....jerry
26th Sep 2016, 8:07 PM
praveen
0
thank you
27th Sep 2016, 5:35 AM
Dinuka