How to call function in Update once

I need to make a function Update checked whether the key is pressed and if so, causes the sound only once, not every frame. But this can be used later to again cause the sound. Code:

 if (Input.GetKey (moveRight))
     {
         if(!isFalling)
         {
             audio.PlayOneShot(stepS);
         }
         rigidbody2D.velocity.x = speed;
         playerAnimator.SetBool("Move", true);
     }

Sorry for bad english

Does it work with this ?

      if (Input.GetKey (moveRight))
      {
          rigidbody2D.velocity.x = speed;
          playerAnimator.SetBool("Move", true);

          if (Input.GetKeyDown (moveRight))
          {
              if(!isFalling)
              {
                  audio.PlayOneShot(stepS);
              }
          }
      }