+ 2
Why is Sololearn Java Different?
https://code.sololearn.com/cT3FpRwQU8XQ/?ref=app With this code, the 'String[ ] args' had to be there but on my pc 'String args[]' works just fine. Why?
3 Answers
+ 7
Because both are correct. For example if you create an integer array you can write
int[] arr = new int[10]; (more common)
or
int arr[] = new int[10];
Same with String[] args / String args[].
Important is that you stick to one variant. Switching between both would confuse you.
If you are not familiar with arrays just ignore it at the moment and read my answer later again.
+ 2
Sololearn code playground accepts both forms.
+ 1
But how Sololearn works with java is different in some other details, and doesn't support GUI