using System;
using System.Collections.Generic;
using System.Linq;

namespace Solution
{
class Program
{
public static void Main(string[] args)
{
var numberList = new List<long>();

numberList.Add(1);
numberList.Add(34);
numberList.Add(3);
numberList.Add(98);
numberList.Add(9);
numberList.Add(76);
numberList.Add(45);
numberList.Add(4);

var numberString = string.Join("", numberList.OrderBy(x => x, new Comparer1()));

Console.WriteLine(numberString);
Console.ReadLine();
}
}
internal class Comparer1 : IComparer<long>
{
public int Compare(long val1, long val2)
{
var str1 = String.Concat(val1.ToString(), val2.ToString());
var str2 = String.Concat(val2.ToString(), val1.ToString());

var num1 = long.Parse(str1);
var num2 = long.Parse(str2);

return num1 == num2 ? 0 : (num1 > num2) ? -1 : 1;
}
}
}