Error CSO116: A namespace can only contain types and namespace declarations

I am a level designer and not a coder or programmer but right now I am a one man team and I need some help solving this error here is the two scripts:

#pragma strict
}
function LoadScene ()

	Application.LoadLevel("Singleplayer");
}

The second one:

#pragma strict
}
function LoadScene ()

Application.LoadLevel("Multiplayer (PVP)");

}

Just like normal parenthesis, the curly brackets are supposed to be opened and closed. Now you have 2 closing brackets in both examples. Also the brackets forming a function body are supposed to be after the function declaration.

 #pragma strict
 
 function LoadScene ()
 {
     Application.LoadLevel("Singleplayer");
 }

Have you remembered to add it to the list of levels used in the game? You may want to make sure you’ve set it up correctly. Here’s a link to the corresponding entry in the Unity Scripting reference for JavaScript: Unity - Scripting API: Application.LoadLevel

Sorry if this doesn’t help, as my experience is mainly with C#.

using UnityEngine;
using System.Collections;

/*
 * Name of file should be same as class name
 * Name of this file should be LoadScene.cs
 */
public class LoadScene : MonoBehaviour {

    public string levelName;
    public int levelNumber;

    /*
     * Type the name exactly as it is in the build settings
     */
    public void LoadLevelByName(string name) 
    {
        Application.LoadLevel(name);
    }

    /*
     * What I use
     * With the name a number exists in the build settings
     * Enter that number in the Editor
     */
    
    public void LoadLevelByNumber(int number)
    {

        Application.LoadLevel(number);
    }

    void Start() 
    { 
        //use either one of the following
        //Load level by name
        LoadLevelByName(levelName);
        //Load level by number
        LoadLevelByNumber(levelNumber);
        
    }
}