我无法在以下php代码中设置单选按钮的“名称”的范围

I want to get the values of radio buttons into database table...Please suggest me for any code modifications:

<?php

$query = mysqli_query($conn,"SELECT * FROM Course_Exit_Survey_Question");

         $array = array();   
         $answer = array();
         echo "<form method='post'>";
         echo "<table border='1'>";
         echo "<tr><th>Question</th></tr>";
         $i=0;
         while ($row = $query->fetch_assoc()) {
               $array[] = $row;
               $var = "{$row['Question']}";
               echo "<tr>";
               echo "<td>";
               echo "<tr><td>$var</td></tr>";
               echo " <td><label>
               <input type='radio' value='1' name='q[<?php echo $i; ?>]'>Poor
               <input type='radio' value='2' name='q[<?php echo $i; ?>]'>Ok
               <input type='radio' value='3' name='q[<?php echo $i; ?>]'>Good
               <input type='radio' value='4' name='q[<?php echo $i; ?>]'>Medium
               <input type='radio' value='5' name='q[<?php echo $i; ?>]'>Excellent
               </label></div></td>";
               $i++;
                          }
         echo "</table>";
if (isset($_POST['submit'])){
   echo "string";
      $q1 = $_POST['q[<?php echo $i; ?>]'];
     $sql= mysqli_query($conn,"INSERT INTO Question_Answer (answer) VALUES ('$q1')") or die("MySQL Error : ".mysqli_error($conn));
      if($sql){
          echo "Data Saved";
       }else{
          echo "Data not saved";
       }
  }

This form asks questions from user which has five options which are provided using radio buttons. When User selects any one out of five option for all questions and clicks submit it should insert all radio button values into database.