#include <bits/stdc++.h>

const int MAXN = 100 + 5;

int N, Ans;
int A[MAXN << 1];

inline int read()
{
	register int x = 0;
	register char ch = getchar();
	while(!isdigit(ch)) ch = getchar();
	while(isdigit(ch))
	{
		x = x * 10 + ch - '0';
		ch = getchar();
	}
	return x;
}

int main()
{
	N = read() << 1;
	for(int i = 1; i <= N; ++i) A[i] = read();
	std::sort(A + 1, A + 1 + N);
	for(int i = 1; i <= N; i += 2) Ans += A[i];
	printf("%d\n", Ans);
	return 0;
}
