print map {$i++ & 1 ? "" : "$_ "} reverse split(/ /);