Third commit. Working version.