a = 'cDOT_stv3027_esx_vdi01_07-24-2021_02.00.00.0443'prefix, *mid, date, time = a.split('_')print(prefix, '_'.join(mid), date, time, sep="\n")
Standard input is empty
cDOT stv3027_esx_vdi01 07-24-2021 02.00.00.0443
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!