Well, here, it's not only an assignment but a declaration, and for
declaration, yes, you have to use def unfortunately.
On Fri, Jan 27, 2017 at 8:37 PM, Les Hartzman wrote:
> Are you saying it needs to be:
>
>def (String string1, String string2) =
Actually, scratch that, the def is required.
Somehow, I feel that it could be made optional, and that would be more
elegant :-)
On Fri, Jan 27, 2017 at 8:13 PM, Guillaume Laforge
wrote:
> I wouldn't use the def:
>
> (String string1, String string2) =
I wouldn't use the def:
(String string1, String string2) = "part1-part2".tokenize("-")
(the def is redundant there)
On Fri, Jan 27, 2017 at 7:55 PM, Dinko Srkoč wrote:
> On 27 January 2017 at 19:15, Les Hartzman wrote:
> > Hi,
> >
> > I just saw a
On 27 January 2017 at 19:15, Les Hartzman wrote:
> Hi,
>
> I just saw a reference to using the above syntax, specifically as follows:
>
>def (string1, string2) = "part1-part2".tokenize("-")
>
> This assigns string1 "part1" and string2 "part2".
>
> So my main question is
Hi,
I just saw a reference to using the above syntax, specifically as follows:
def (string1, string2) = "part1-part2".tokenize("-")
This assigns string1 "part1" and string2 "part2".
So my main question is what is this referred to as?
You can't do:
String (string1, string2) =