#include <cstdio>
#include <cmath>
#include <cstring>
#include <cstdlib>
#include <ctime>
#include <cassert>
#include <algorithm>
#include <iostream>
#include <vector>
#include <set>
#include <map>
#include <string>
#include <queue>

using namespace std;

typedef long long ll;

#define pb push_back
#define sz(a) (int)a.size()
#define zero(a) memset (a, 0, sizeof(a))
#define mp make_pair

#define taskname "hear"

vector<int> v;
vector<int> v2;

vector<vector<int> > ans;
vector<int> cur;
const int thousand = 1000;
const int million = thousand * thousand;

void add(int a,int b){
	if (a == 0)
		return;
	if (a >= 100)
		v.pb((a/100)*100);
	a %= 100;      
	if (a >= 20){
		v.pb((a/10)*10), a %= 10;
	}
	//cerr << "!!!"<<v.back() << endl;
  if (a == 0)
  	v.back() *= b;
  else        
		v.pb(a*b);
}           

void addint(int a){
	add(a/million,million);
	add((a/thousand)%thousand,thousand);
	add(a%thousand,1);
}

void print(vector<int>& v){
  for (int i = 0; i < (int)v.size(); i++)
  	printf("%d%c",v[i],"-\n"[i+1 == (int)v.size()]);
}


bool check(int a,int b){
	if (a == 0)
		return true;
	if (b >= million){
		if (b / million < 10)
		   return a < thousand && a % 10 == 0 && a%100 != 10;
		if (b / million < 100)
			 return a < thousand && a % 100 == 0;
		return false;
	}

	if (b >= thousand){
		a %= million;
		if (a == 0)
			return true;
		if (a>=thousand)
			return false;
	  if (b / thousand < 10)
	  	return a < thousand && a % 10 == 0 && a%100 != 10;
	  if (b / thousand < 100)
	  	return a < thousand && a % 100 == 0;
	  return false;
	}
	             

	if (b >= 100)
		return a % thousand == 0;
	if (b >= 10)
		return a % 100 == 0;
	return a % 10 == 0 && a % 100 != 10;	
}

int merge(int a,int b){
	if (a == 0)
		return b;
	if (b >= million)
		return a * million + b;
	

	if (b >= thousand){
		int c = a / million;
		a %= million;
	  return c*million + a *thousand + b;
	}
	             
	return a + b;
}

void gen(int id,int current){
	if (current){
		cur.pb(current);
		gen(id,0);
		cur.pop_back();
	}
	if (id == (int)v.size()){
		if (current)
			return;
		ans.pb(cur);
		return;
	}

	if (check(current,v[id]))
		gen(id+1,merge(current,v[id]));
  
}

int main (void)
{
  freopen (taskname".in", "r", stdin);
  freopen (taskname".out", "w", stdout);

  for (int a; scanf("%d",&a) == 1;scanf("-"))
  	addint(a);
                      
  for (int i = 0; i < (int)v.size(); i++)
  	  if (v[i])
  	  	v2.pb(v[i]);
  v = v2;
  //print(v);
  //return 0;

  gen(0,0);
                                                    
  printf("%d\n",ans.size());
  for (int i = 0; i < (int)ans.size(); i++)
  	print(ans[i]);
  return 0;
}

