Random scripts and applications