Alternative approaches to addressing JavaScript scoping issues
===

As of now, I've been using self-executing anonymous functions in order to avoid having variable naming issues: 

    (function () {
        var a, b, c;
        a = 5;
        b = 10;
        c = 15;
        console.log('No problema!');
    ]());

I also know that using the onload function is also an alternative approach: 

    window.onload = function () {
        var a;
        a = 25;
        console.log('Yay!!!');
    }

But I really dislike how my code is completely trapped inside a function - is there an approach that I could take with JavaScript objects that could help me avoid using self-executing functions? 