Increasing score based on speed

I am having trouble increasing score based on speed of the car with a few lines of code. I know how to do it with score vs time with

, and I know how to this with 5 or 6 conditions and 20 lines of code ,but I wanted to do this with a few lines of code. It’s possible ?.

What I want is:
Score + = 1 point every 1 second if car speed = 1.
Score + = 1 point every 0.8 seconds if car speed = 3
Score + = 1 point every 0.6 seconds if car speed = 6.
Score + = 1 point every 0.4 seconds if car speed = 9.
Score + = 1 point every 0.2 seconds if car speed> 9.

I m using two Coroutines, one for score and another for speed, activated on Start function:

     private IEnumerator ChangeSpeed()
     {
         while (true){
             yield return new WaitForSeconds(1);
                 if(speed < 2.0f || speed < 9.0f && gameStart){
                     speed += 3.0f;
                 }
        
             if(speeding)
                 velocity = speed + 1f;
             else
                 velocity = speed;
         }
     }
     private IEnumerator ChangeScore()
     {
         while (true){
             yield return new WaitForSeconds(1);
             if(gameStart){
                 scoreNum += 1;
                 scoreText.text = scoreNum.ToString();
             }
         }
     }

This isn’t meant to be fully functional code, but this is one way you could organize this.

Basically you keep a “tier” or “multiplier” or something to use to alter speed and point gain interval.

public float speedPerTier = 3;
public float minSpeed = 1f;
public float maxPointInterval = 1f;
public float pointIntervalPerTier = .02f;
public int tiers = 4;

private int tier;
private float speed;
private float pointInterval;
private float points;

private IEnumerator Start() {
    while(enabled) {
        tier = Mathf.Min(tier + 1, tiers);
        speed = Mathf.Max(speedPerTier * tier, minSpeed);
        pointInterval = maxPointInterval - (pointIntervalPerTier * tier);
        points++;

        yield return new WaitForSeconds(pointInterval);
    }
}

thanks. I opted for a direct solution from Major user and worked well.

This was the solucion:

private IEnumerator ChangeScore()
    {
        while (true){

            yield return new WaitForSeconds(waitTime);

            if (speed <= 1f) {
                waitTime = 0.3f;
            }
            else if (speed >1.0f && speed <= 8.0f) {
                waitTime = -0.05f * speed + 0.5f;
            }
            else if (speed > 8.0f) {
                waitTime = 0.1f;
            }


            if(gameStart){

                scoreNum += 1;

                scoreText.text = scoreNum.ToString();
            }
        }
    }