Placing groups of computers into Maintenance Mode

Boris has created a great PowerShell script for placing groups of computers into maintenance mode. See https://blogs.msdn.com/boris_yanushpolsky/archive/2008/03/04/one-more-maintenance-mode-script.aspx