how can i create this with Mathematica?

 how can i create this with Mathematica?

Tried a bunch of different things for pass-fail but I couldn’t get the outcome that the exerise wants

Here’s my code

marks =[45, 50, 89, 59, 82, 47, 99]

for grade in marks: if grade >= 50: print ‘Pass’

This prints “Pass” 5 times. The thing says there are not enough lines, so i tried code that pints “Fail” for the grades below 50 and it tells me that a print statement is incorrect. So I tried printing blank spaces for the failed grades, and i still told me that a print statement is incorrect. What is this exercise actually looking for as an outcome?

Let’s block ads! (Why?)

Recent Questions – Mathematica Stack Exchange