#include "bits/stdc++.h"
#include<unordered_map>
#include<unordered_set>
#pragma warning(disable:4996)
using namespace std;

bool try_insert(map<int,int>&mp,const vector<int>&anss, int place,int rest, int l, int r) {
	vector<int>del_nums;

	if(l==place){
		int sum=anss[place];
		del_nums.push_back(sum);
		for (int x = l - 1; x >= 0; --x) {
			sum+=anss[x];
			del_nums.push_back(sum);
		}

		sum=rest-anss[place];
		del_nums.push_back(sum);
		for (int x = r; x < anss.size(); ++x) {
			sum+=anss[x];
			del_nums.push_back(sum);
		}
	}
	else {
		int sum = rest-anss[place];
		del_nums.push_back(sum);
		for (int x = l - 1; x >= 0; --x) {
			sum += anss[x];
			del_nums.push_back(sum);
		}

		sum = anss[place];
		del_nums.push_back(sum);
		for (int x = r; x < anss.size(); ++x) {
			sum+=anss[x];
			del_nums.push_back(sum);
		}
	}
	for (auto del_num : del_nums) {
		auto m=mp.find(del_num);
		if(m==mp.end())return false;
		else {
			mp[del_num]--;
			if(mp[del_num]==0)mp.erase(m);
		}
	}
	return true;
}

vector<vector<int>>answers;

void dfs(const vector<int>&anss, int rest,map<int,int>&v,int l,int r) {
	if (l + 1 == r) {
		assert(v.empty());
		{
			auto n_anss(anss);
			n_anss[l]=rest;
			answers.push_back(n_anss);
		}
		return ;
	}
	else {
		int max_num = prev(v.end())->first;
		{
			int l_num = max_num - accumulate(anss.begin(), anss.begin() + l, 0);
			if (l_num <= 0) {
			}
			else {
				map<int, int>next_v(v);
				auto n_anss(anss);
				n_anss[l] = l_num;
				if (try_insert(next_v, n_anss, l, rest, l, r)) {
					dfs(n_anss, rest - l_num, next_v, l + 1, r);
				}
			}


		}
		{
			int l_num = (rest + accumulate(anss.begin() + r, anss.end(), 0)) - max_num;
			if (l_num <= 0) {
			}
			else {
				map<int, int>next_v(v);
				auto n_anss(anss);
				n_anss[l] = l_num;
				if (try_insert(next_v, n_anss, l, rest, l, r)) {
					dfs(n_anss, rest - l_num, next_v, l + 1, r);
				}
			}
		}
		{
			int r_num = max_num - accumulate(anss.begin() + r, anss.end(), 0);
			if (r_num <= 0) {
			}
			else {
				map<int, int>next_v(v);
				auto n_anss(anss);
				n_anss[r - 1] = r_num;
				if (try_insert(next_v, n_anss, r - 1, rest, l, r)) {
					dfs(n_anss, rest - r_num, next_v, l, r - 1);
				}
			}
		}
		{
			int r_num = (rest + accumulate(anss.begin(), anss.begin() + l, 0)) - max_num;
			if (r_num <= 0) {
			}
			else {
				map<int, int>next_v(v);
				auto n_anss(anss);
				n_anss[r - 1] = r_num;
				if (try_insert(next_v, n_anss, r - 1, rest, l, r)) {
					dfs(n_anss, rest - r_num, next_v, l, r - 1);
				}
			}
		}
		return ;
	}
	
}

void solve(int N) {
	vector<int>v(N*(N-1)/2);
	map<int,int>mp;
	for(int i=0;i<(N*(N-1))/2;++i)cin>>v[i];
	for(int i=1;i<(N*(N-1))/2;++i)mp[v[i]]++;

	if (N ==2) {
		answers=(vector<vector<int>>{vector<int>{1}});
	}
	else {

		vector<int>anss(N - 1, -1);
		dfs(anss, v[0], mp, 0, N - 1);
	}
}

bool operator <(const vector<int>&l, const vector<int>&r) {
	for (int i = 0; i < l.size(); ++i) {
		if(l[i]<r[i])return true;
		else if(l[i]>r[i])return false;
	}
	return false;
}

int main()
{
	int N;
	while (cin >> N) {
		if(!N)break;
		answers.clear();
		solve(N);
		sort(answers.begin(),answers.end());
		answers.erase(unique(answers.begin(),answers.end()),answers.end());
		for (auto answer : answers) {
			for (int k = 0; k < N-1; ++k) {
				cout<<answer[k];
				if(k==N-2)cout<<endl;
				else cout<<" ";
			}
		}
		cout<<"-----"<<endl;
	}

	return 0;
}



Measured memory_bytes: 3284