<>=~$";sub f{my$d=$_%-$';($_=($_-$d)/$')?&f:'',$d}print f,$/for<>