$q was declared but not used