Javascript:

    function program() {
        var input = [];
        do {
            var num = prompt('Enter a number, or nothing to continue');
            if (num == 'nothing') {
                break;
            }
            input.push(parseDouble(num));
        } while (true);

        var sorted = [];
        return sorted;
    }

    function parseDouble(str) {
        return parseFloat(str);
    }

1. Ending the input sequence requires literally typing "nothing" (case-sensitive and everything).
2. You've got to create a `parseDouble` method, because obviously you're not getting _doubles_ otherwise.
3. Returns the array `sorted`.