Write a program that outputs the `n` largest elements from a list.
Example:
```python
largest(2, [7,6,5,4,3,2,1])
# => [6,7]
```
def largest(n,xs):
    lst = sorted(xs)
    new = []
    for i in range(n):
        new.append(lst[-i-1])
    return sorted(new)

def largest(n,xs):
    lst = sorted(xs)
    new = []
    for i in range(n):
        new.append(lst[-i-1])
    return sorted(new)
