#include<iostream>
#include<cstdio>
#include<algorithm>
using namespace std;
int n,a[210];
int main()
{
	cin>>n;
	for(int i=1;i<=2*n;++i){
		scanf("%d",a+i);
	}
	sort(a+1,a+2*n+1);
	int ans=0;
	for(int i=1;i<=2*n;i+=2){
		ans+=a[i];
	}
	cout<<ans<<endl;
}