human
Write me a the Python program you requested given the following:
I am working on the file "ANTLR4-Python/LR-Parser-Generator/LR-Table-Generator.ipynb".
The first task is:
The class MarkedRule is similar to the class ExtendedMarkedRule but does not have the follow set.
Can you write Python program for it?
assistant
#Here is the Python program you requested.

class MarkedRule():
    def __init__(self, variable, alpha, beta):
        self.mVariable = variable
        self.mAlpha    = alpha
        self.mBeta     = beta
        
    def __eq__(self, other):
        return isinstance(other, MarkedRule)     and \
               self.mVariable == other.mVariable and \
               self.mAlpha    == other.mAlpha    and \
               self.mBeta     == other.mBeta     
    
    def __ne__(self, other):
        return not self.__eq__(other)
    
    def __hash__(self):
        return hash(self.mVariable) + \
               hash(self.mAlpha)    + \
               hash(self.mBeta)     
    
    def __repr__(self):
        alphaStr  = ' '.join(self.mAlpha)
        betaStr   = ' '.join(self.mBeta)
        return f'{self.mVariable} → {alphaStr} • {betaStr}'