```\n// SPDX-License-Identifier: UNLICENSED\npragma solidity 0.8.21;\n\nimport { SafeCast } from "@openzeppelin/contracts/utils/math/SafeCast.sol";\n\nerror BrokenTokenPriceFeed();\n\ncontract PassWithNegativePrice {\n\n    using SafeCast for int256;\n\n    uint256 public maxDeviations;\n    int256 public currentResponse;\n    int256 public prevResponse;\n    uint8 public decimal;\n    \n    constructor(int256 _currentResponse, int256 _prevResponse, uint8 _decimal,uint256 _maxDeviation )  {\n        currentResponse = _currentResponse; //  _currentResponse > 0 e.g. 2000, 3, 90000000000000\n        prevResponse = _prevResponse; // _prevResponse < 0  e.g. -3000, -1 \n        decimal = _decimal; // _decimal can be 8, 18\n        maxDeviations = _maxDeviation; // any value\n    } \n    \n    // You call this function,  result is currentResponse but doesn't matter  maxDeviations value\n    function consultIn18Decimals() external view  returns (uint256) {\n    \n        (int256 _answer, uint8 _decimals) =  consult();\n\n        return _answer.toUint256() * 1e18 / (10 ** _decimals);\n    }\n\n    function consult() internal view  returns (int256, uint8) { \n\n        if (_badPriceDeviation(currentResponse, prevResponse) )revert  BrokenTokenPriceFeed();\n\n        return (currentResponse, decimal);\n    }\n\n    function _badPriceDeviation(int256 _currentResponse, int256 _prevResponse ) internal view returns (bool) {\n    // Check for a deviation that is too large\n        uint256 _deviation;\n\n        if (_currentResponse > _prevResponse) { // Here is our scene, always result be zero with negative value of _prevResponse\n        _deviation = uint256(_currentResponse - _prevResponse) * 1e18 / uint256(_prevResponse);\n        } else {\n        _deviation = uint256(_prevResponse - _currentResponse) * 1e18 / uint256(_prevResponse);\n        }\n\n        return _deviation > maxDeviations;\n    }\n\n\n}\n```\n