<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _is_valid_heading(self):
 """ Check that the headings of page are sintatic correct. :return: True if the headings of page are sintatic correct or False if not. :rtype: bool """


        elements = self.parser.find('h1,h2,h3,h4,h5,h6').list_results()
        last_level = 0
        count_main_heading = 0
        self.validate_heading = True
        for element in elements:
            level = self._get_heading_level(element)
            if level == 1:
                if count_main_heading == 1:
                    return False
                else:
                    count_main_heading = 1
            if (level - last_level) > 1:
                return False
            last_level = level
        return True