Suppose a is a group of strings.
I can not understand the difference between String[] a and
String a[]
Is both of them have the same meaning?I need the answer based on android
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
If you’re asking about Java, then, yes, both have the same meaning.
String[] ais preferred since it keeps the entire type definition together and visually distinct from the identifier.String a[]is only in the language to make it easier forC++andCprogrammers to learn. The Java language creators were initially trying to convince C++ developers to learn Java by adopting a familiar syntax.