How to move <h2> to center? I tried so many times :( :(
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta http-equiv="X-UA-Compatible" content="ie=edge"> <title>Table 02</title> </head> <body> <!DOCTYPE html> <html> <head> <style> table { text-align: center; font-family: arial, sans-serif; border-collapse: collapse; width: 100%; } td, th { background-color: yellow; text-align: center; border: 1px solid grey; text-align: left; padding: 8px; } td, th{ text-align: center; } tr:nth-child{ background-color: yellow; } </style> </head> <body> <h2>HTML Table Sample 02</h2> <table> <tr> <th>Full Name</th> <th>Sex</th> <th>Age</th> <th>City</th> </tr> <tr> <td>Kiyoshi Teppei</td> <td>M</td> <td>18</td> <td>Tokyo</td> </tr> <tr> <td>Kagami Tiga</td> <td>M</td> <td>17</td> <td>Berlin</td> </tr> <tr> <td>Riko Aida</td> <td>F</td> <td>16</td> <td>Moscow</td> </tr> <tr> <td>Aomine Daiki</td> <td>M</td> <td>17</td> <td>Denver</td> </tr> </table> </body> </html> </body> </html>