Rewrite tablegenerator | Computer Science homework help