Groovy web console

subscribe to the feed Subscribe
to this
site

passing var to a method

Published 4 months ago by Szymek Kurdziel
Actions Execute script  ▶ Edit in console Back to console Show/hide line numbers View recent scripts
void changeNameAndSurname(String x){
x="Szymon Kurdziel"
}

String a="Mateusz Grzybowski"
println a
changeNameAndSurname(a)
println a