(cls, value, *args)
return cls(mtrx)
Creates a matrix filled with the given value

        @param value: the value to be used
        @keyword shape: the shape of the matrix. Can be a single integer,
          two integers or a tuple. If a single integer is
          given here, the matrix is assumed to be square-shaped.
Creates a matrix filled with the given value
Creates a matrix filled with the given value
def Fill(cls, value, *args):
        """Creates a matrix filled with the given value

        @param value: the value to be used
        @keyword shape: the shape of the matrix. Can be a single integer,
          two integers or a tuple. If a single integer is
          given here, the matrix is assumed to be square-shaped.
        """
        if len(args) < 1:
            raise TypeError("expected an integer or a tuple")
        if len(args) == 1:
            if hasattr(args[0], "__len__"):
                height, width = int(args[0][0]), int(args[0][1])
            else:
                height, width = int(args[0]), int(args[0])
        else:
            height, width = int(args[0]), int(args[1])
        mtrx = [[value] * width for _ in range(height)]
        return cls(mtrx)
def Fill ( cls , value , * args ) : if len ( args ) < 1 : raise TypeError ( "expected an integer or a tuple" ) if len ( args ) == 1 : if hasattr ( args [ 0 ] , "__len__" ) : height , width = int ( args [ 0 ] [ 0 ] ) , int ( args [ 0 ] [ 1 ] ) else : height , width = int ( args [ 0 ] ) , int ( args [ 0 ] ) else : height , width = int ( args [ 0 ] ) , int ( args [ 1 ] ) mtrx = [ [ value ] * width for _ in range ( height ) ] return cls ( mtrx )