New block: Round by {number}
-
There’s a slight annoyance with the round block: It only rounds to the nearest ones place. What if instead of just that, you can choose from any digit (a few, for example, would be the hundredth, tenth, ones, or any decimal point place).
This block would be a typing output and not a clicking output so they can choose any digit place to round up/down to.
-
@the_true_odst you can do this already in a simple way. Multiply the number 10 to the number of places you want (so for 3 places 10^3 or 1000), round it, then divide by that number
For example, to round the variable “money” to the 2nd decimal: round( money * 100) / 100
-
@the_true_odst you can do this already in a simple way. Multiply the number 10 to the number of places you want (so for 3 places 10^3 or 1000), round it, then divide by that number
For example, to round the variable “money” to the 2nd decimal: round( money * 100) / 100
@tyller_ It would be simpler though
-
@the_true_odst you can do this already in a simple way. Multiply the number 10 to the number of places you want (so for 3 places 10^3 or 1000), round it, then divide by that number
For example, to round the variable “money” to the 2nd decimal: round( money * 100) / 100
@tyller_ it would be a lot easier
-
There’s a slight annoyance with the round block: It only rounds to the nearest ones place. What if instead of just that, you can choose from any digit (a few, for example, would be the hundredth, tenth, ones, or any decimal point place).
This block would be a typing output and not a clicking output so they can choose any digit place to round up/down to.
Yes. And another issue is that the round block is from the original MIT Scratch, and we try to keep those blocks unchanged for compatibility.
-
Yes. And another issue is that the round block is from the original MIT Scratch, and we try to keep those blocks unchanged for compatibility.
@info-creaticode What about a new block?
-
@tyller_ It would be simpler though
@the_true_odst well that method is already pretty simple, plus you could make a custom block to do it
-
@tyller_ it would be a lot easier
@attractive-milk well this one is already easy, I just suck at explaining stuff in simple ways
-
@info-creaticode What about a new block?
@the_true_odst said in New block: Round by {number}:
What about a new block?
Well, it will be a bit confusing with 2 “round” blocks. Also, as shown, it is fairly easy to work around it, right?

Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login