#include <cstdio>
#include <algorithm>
int a[205];
int main() {
	int n;scanf("%d",&n);
	for(int i=0;i<(n<<1);++i) scanf("%d",&a[i]);
	std::sort(a,a+2*n);
	int ans=0;
	for(int i=0;i<(n<<1);i+=2) ans+=a[i];
	printf("%d\n",ans);
	return 0;
}
