Help needed with player jumping.

Hello, i am in need of some help with my playercontroller script. I was able to program the movements just fine and even figured out how to allow the player to jump, however i have encountered a small problem. The player can press the jump button, space in this case, multiple times and rise indefinitly. I would really like to know what to add to my code in order to only allow the player to jump once while on the ground but not jump while in the air. Here is my code…

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

public class PlayerController : MonoBehaviour
{
    public Rigidbody rb;
    public float moveSpeed = 10f;
    public Vector3 jump;

    private float xInput;
    private float zInput;

    // Start is called before the first frame update
    void Start()
    {
       
    }

    // Update is called once per frame
    void Update()
    {
        // Good for handling inputs and animaitons
        ProcessInputs();

        if (Input.GetKeyDown("space"))
        {
            Vector3 jump = new Vector3(0.0f, 200.0f, 0.0f);
            GetComponent<Rigidbody>().AddForce(jump);
        }
    }

    void FixedUpdate()
    {
        Move();
        // Movement

    }

    private void ProcessInputs()
    {
        xInput = Input.GetAxis("Horizontal");
        zInput = Input.GetAxis("Vertical");
    }
    private void Move()
    {
        rb.AddForce(new Vector3(xInput, 0f, zInput) * moveSpeed);
    }
}

If anyone could show me the proper code and possibly explain how it works i would really appreciate it. Thank you.

No need for anyone to reply here, ive got help on another thread. Thank you!