For 2. you can just do:

tokenize 44 $$2
write file.txt $*

EDIT: Just noticed DaveC already used that.