SOURCE

let arg = `2024-08-01 15:49:39.000
2024-08-01 14:31:59.000
2024-08-01 12:06:34.000
2024-08-01 11:52:42.000
2024-08-01 11:41:52.000
2024-08-01 10:50:11.000
2024-07-31 22:59:56.000
2024-07-31 20:02:59.000
2024-07-31 18:33:33.000
2024-07-31 18:02:05.000
2024-07-31 16:57:45.000
2024-07-31 15:13:04.000
2024-07-31 15:02:53.000
2024-07-31 13:25:50.000
2024-07-31 12:30:14.000
2024-07-31 10:22:53.000
2024-07-31 06:34:59.000
2024-07-31 05:47:34.000
2024-07-31 04:53:44.000
2024-07-31 03:09:05.000
2024-07-31 01:21:54.000
2024-07-31 01:17:49.000
2024-07-31 00:21:33.000
2024-07-30 23:42:20.000
2024-07-30 23:25:15.000
2024-07-30 17:00:21.000
2024-07-30 12:41:52.000
2024-07-30 11:02:44.000
2024-07-30 10:49:21.000
2024-07-30 07:51:30.000
2024-07-30 03:39:39.000
2024-07-30 02:48:14.000
2024-07-30 01:52:39.000
2024-07-30 01:37:43.000
2024-07-29 23:32:59.000
2024-07-29 21:04:30.000
2024-07-29 20:35:46.000
2024-07-29 20:01:58.000
2024-07-29 18:21:07.000
2024-07-29 17:14:41.000
2024-07-29 17:03:50.000
2024-07-29 16:41:32.000
2024-07-29 16:28:37.000
2024-07-29 16:14:34.000
2024-07-29 15:02:14.000
2024-07-29 11:55:17.000
2024-07-29 11:25:43.000
2024-07-29 10:16:47.000
2024-07-29 09:54:04.000
2024-04-14 19:18:01.000
2024-04-14 19:18:01.000
2024-04-14 19:18:01.000
2024-04-14 19:18:01.000`



let list = arg.split('\n')
// console.log('list:', list)

let result = []
let resultT = []
list.forEach(e=>{
    let l = e.split(' ')
    let a = l[0].split('-').join('')
    let b = l[1].split('.')[0].split(':').join('')
    result.push('O'+a+''+b+randomWord(13))
    resultT.push('T'+a+''+b+randomWord(13))
})

console.log(result.join('\t'))
console.log('-----------')
console.log(resultT.join('\t'))
console.log('结束')

function randomWord(length=32){//默认32位
			//由以下元素组成
            // let arr=['0','1','2','3','4','5','6','7','8','9','A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z'];
            let arr=['0','1','2','3','4','5','6','7','8','9'];
            let num='';
            for(let i=0;i<length;i++){
                num+=arr[parseInt(Math.random()*arr.length)];
            }
            return num;
        }
console 命令行工具 X clear

                    
>
console