TypeError: 'numpy.float64' object cannot be interpreted as an integer

Is there example code to move on from this lab? I’m getting errors and I can’t figure out what’s going on.

Here is my code for the first question:

{moderator edit: code removed}

This part should be indented -
{code removed}

Maybe, n is referreing to some previous value which had numpy.float64 as datatype.

@Ray_Fang ,
Please do not post your code on the forum. That’s not allowed by the course community standards.

If a mentor wants to see your code, we’ll ask you to send it to us via a private message.

I have edited your message to remove the code.