yield WaitForSeconds unexpected symbol

Hello All. I’m currently adding some functionality to the first “Roll A Ball” application as I learn Unity for the first time. I wanted to display the Win text for X number of seconds so I found the yield WaitForSeconds function. The issue is that the compiler in MonoDevelop-Unity application gives me an error:

Assets/Scripts/PlayerController.cs(13,17): error CS0246: The type or namespace name `List`1' could not be found. Are you missing a using directive or an assembly reference?

All I did was add this to the “SetCountText()” function as below:

	void SetCountText(){
		countText.text = "Count: " + count.ToString ();
		if (count >= 17) {
			winText.text = "This game is terrible. You should get a refund.";
			yield WaitForSeconds(5f);
		}
	}

Any ideas? Am I missing some special namespace or something? I’m currently using:
using UnityEngine;
using System.Collections;
using System.Collections.Generic;
using UnityEngine.UI;

WaitForSeconds is a class, so it needs to be instantiated with the ‘new’ keyword. Try this:

yield return new WaitForSeconds(5f);

Also, it only works in a function that supports it, namely a function that returns IEnumerator. Check this article out for more info.

hey, none of this worked? well, try this one…

    IEnumerator WaitForSec(float secounds)
    {
    Debug.Log("our wait has started");
    yield return new WaitForSeconds(secounds);
    Debug.Log("our wait has started");
    }