does anyone know if there is a block like (x)^(y) in scratch? if not, how would you do it in BYOB without having an infinite amount of "if" statements?
Offline
x^y = 10^ (y * log x)
That should work.
([10^] of ((y) * ([log] of (x))))Edit: In response to your question, there isn't an actual block, but there is a suggestion to make that in Scratch Suggestions here
Last edited by MoreGamesNow (2012-02-29 18:31:39)
Offline
MrMonk999 wrote:
when gf clicked set <z> to (1) repeat <y> set <z> to <<z> * <x>>
Actually it'd need to be
repeat ((y)-[1])But that doesn't work with decimals or negative numbers anyway.
Offline