I call "prank" on this. Either that, or "lousy teacher". If the kids all log off 5 minutes too soon, inform them at the start of the lesson that pending adjustment, the clocks on their workstations are to be disregarded, and log off time is when teacher says it is. That's not rocket science.
If all of the clocks are exactly 5 minutes fast, (why?) then in a room full of locked down school computers, you want someone who knows the BIOS password going around to each machine with an accurate watch, or else set the machines to sync from the internet or a server. A batch file is the very last thing you want.
This looks like one of those questions that we get where the poster obviously thinks that computer help forums are run, and contributed to, by clueless 13 year old nerds who have no knowledge of the real world outside the case of a PC.