Just to show how versatile bash is, here's a way to do what you want without using sudo: create a file as root, let's say /usr/local/update that looks like this:
#! /bin/bash

Then, still as root, run chmod /usr/local/update +x, +s /usr/local/update which means that anybody can execute the file as though they were the file's owner, allowing them to update your system without needing to enter a password. (I picked /usr/local because it's on the default path.) Which way you use depends on your own personal taste, of course, but I find the above to be a bit more elegant. YMMV and probably does.