Script I copied from Movement tutorial doesnt work

Hi, newbie here. I followed this tutorial: “Moving the Player” “https://unity3d.com/es/learn/tutorials/projects/roll-a-ball/moving-the-player” ,and copied the script, this is my script:

using UnityEngine;

using System.Collections;

public class PlayerController : MonoBehaviour {

public float speed;
private Rigidbody rb;
void Start ()
{
	rb = GetComponent<Rigidbody>();
}
void FixedUpdate ()
{
	float moveHorizontal = Input.GetAxis ("Horizontal");
	float moveVertical = Input.GetAxis ("Vertical");
	Vector3 movement = new Vector3 (moveHorizontal, 0.0f, moveVertical);
	rb.AddForce (movement);
}

}

And is attached to the ball wich has “Player” as name.
When I try to play, the console window it says: “The referenced script on this Behaviour is missing!”. Twice.

On the inspector window, under the script that has “movementBall” as name, it says:
“The associated script can not be loaded.
Please fix any compile errors
and assign a valid script”.
I made sure that the bal has the rigid body component.

It seems your script is named wrong.

public class PlayerController : MonoBehaviour {

If your class is “PlayerController.cs” your script has to be named as PlayerController.cs and not as “movementBall.cs”. So finally scriptname has to be same like classname and vise versa. Name your script PlayerController.cs or change the line I posted before to:

public class movementBall : MonoBehaviour {

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.InputSystem;

public class PlayerController : MonoBehaviour
{
public float speed = 0;

private Rigidbody rb;

private float movementX;
private float movementY;

// Start is called before the first frame update
void Start()
{
    rb = GetComponent<Rigidbody>();
}

private void OnMove(InputValue movementValue)
{
    Vector2 movementVector = movementValue.Get<Vector2>();

    movementX = movementVector.x;
    movementY = movementVector.y;
}

private void FixedUpdate()
{
    Vector3 movement = new Vector3(movementX, 0.0f, movementY);

    rb.AddForce(movement * speed);
}

}