package main import . "fmt" import . "sort" func main() { var n,k int Scan(&n,&k) a:=make([]int,n,n) for i:=range a { Scan(&a[i]) } Ints(a) var s int = a[n-1] for i:=1;i0 { s+=x } } Println(s) }