Groovy web console

subscribe to the feed Subscribe
to this
site
n to the power of number (via #groovywebconsole)
tweet this snippet Tweet
this
script

n to the power of number

Published 3 months ago by Groover
Actions  ➤ Edit in console Back to console Show/hide line numbers View recent scripts
int n=10
List list =new ArrayList()
for (i=0;i<n;i++){
    list.add(Math.pow(3,i))
}
println list