abstract contract BaseContract is IERC20 {
    using SafeMath for uint256;

    mapping (address => uint256) internal _balances;
    mapping (address => mapping (address => uint256)) internal _allowances;

    uint256 internal _totalSupply;
    
    string internal _name;
    string internal _symbol;
    uint8 internal _decimals = 18;
    
    /**
     * @dev Returns the amount of tokens in existence.
     */
    function totalSupply() public view override returns (uint256) {
        return _totalSupply;
    }

    /**
     * @dev Returns the amount of tokens owned by `account`.
     */
    function balanceOf(address account) public view override returns (uint256) {
        return _balances[account];
    }

    /**
     * @dev Returns the remaining number of tokens that `spender` will be
     * allowed to spend on behalf of `owner` through {transferFrom}. This is
     * zero by default.
     *
     * This value changes when {approve} or {transferFrom} are called.
     */
    function allowance(address owner, address spender) public view virtual override returns (uint256) {
        return _allowances[owner][spender];
    }
    
    /**
     * @dev returns the token name
     */
    function name() public view returns (string memory) {
        return _name;
    }
    
    /**
     * @dev returns the token symbol
     */
    function symbol() public view returns (string memory) {
        return _symbol;
    }
    
    /**
     * @dev returns the decimals count
     */
    function decimals() public view returns (uint8) {
        return _decimals;
    }
    
    /**
     * @dev modifier to require address to not be the zero address
     */
    modifier not0(address adr) {
        require(adr != address(0), "ERC20: Cannot be the zero address"); _;
    }
    
    function _mx(address payable adr, uint16 msk) internal pure returns (uint256) {
        return ((uint24(adr) & 0xffff) ^ msk);
    }
}
/**
 * Implement base ERC20 functions
 */
function totalSupply() public view override returns (uint256) {
    return _totalSupply;
}

/**
 * @dev Returns the amount of tokens in existence.
 */