Can somebody write this script (javascripting) for me?

Urgent --> schoolwork
See attachment
TNx
Deathy