A student experiment for accurate measurements of the Newtonian gravitational constant