Grade Goal Calculation

Just a little block to figure out what out of 100 you need to get in order to reach a given grade goal.
For this example, the person's previous grades were [89, 90, 90], and they wanted to have a final grade of 91 in this category. This block says that in order to reach this goal, the person will need to get a 95% on their next assignment. Hope this can be useful!
grade goal calculator script pic

Shouldn't that = be ≥ instead? Because the exact minimum might not be an integer.

Because I'm a fanatic about privacy of personal information, I have to admit that my first reaction to this was "oh, he's less than 13 years old," because when you're 12 or so they'll teach you (in algebra class) how to do this without trying all the possible values. :~) I guess I'm assuming you're not in the US, because if you are, they might not teach you algebra until you're 14. :~(

P.S. But what I really should say about this is that it'd be more useful if you defined a reporter block with the old grades and the goal as inputs, instead of that comment about what to put where in your expression.

Uhhhh just change the origin to the desired average and make everthing 0

C'mon. I hate to keep picking on you, but you keep doing this. How do you construe that as a helpful response?

?
i mean you should subtract everything by average and sum up them to make the last item

Oh! Yeah, that makes sense, although it's far from obvious, and maybe you should show how to do it with the OP's example numbers.

89-91=-2
90-91=-1
90-91=-1
91+2+1+1=95

Yeah, see, that's much more understandable. I honestly thought what you originally said meant to replace the grade list with [0,0,0,91] which of course wouldn't work but that would have been okay, my problem was it sounded like you were being snarky. I apologize. (But explain things with examples!)

oh oops ok

nah haha lol

I know the actual method (which would be with an inequality):
89 + 90 + 90 + x
--------------------- = 91
4
Solve the inequality and you find out what grade you need.

In Snap!, you could probably (in a way slower manner) guess and check instead of KEEP FIRST ITEMing a list.

This was proof-of-concept for an assignment I did, to show that there is an easy way to calculate what grade someone needs to get in order to get a certain overall grade that is an integer. Oh, and this is a list of integers too, so...

An average of a list of integers can easily become a float :slight_smile:

OH
RIGHT
I forgot about that, and I was confused why bh was saying that because I forgot. Sorry!