BasicMath

Description:

Smart contract deployed on Ethereum with Factory features.

Blockchain: Ethereum

Source Code: View Code On The Blockchain

Solidity Source Code:

{{
  "language": "Solidity",
  "sources": {
    "contracts/Kontract.sol": {
      "content": "// SPDX-License-Identifier: MIT\r
pragma solidity ^0.8.0;\r
\r
contract BasicMath {\r
    uint256 constant MAX_INT = type(uint256).max;\r
\r
    function adder(uint256 _a, uint256 _b) external pure returns (uint256 sum, bool error) {\r
        if (_b > MAX_INT - _a) {\r
            return (0, true); // Overflow occurred\r
        }\r
        return (_a + _b, false);\r
    }\r
\r
function subtractor(uint256 _a, uint256 _b) external pure returns (uint256 difference, bool error) {\r
        if (_b > _a) {\r
            return (0, true); // Underflow occurred\r
        }\r
        return (_a - _b, false);\r
    }\r
}"
    }
  },
  "settings": {
    "optimizer": {
      "enabled": false,
      "runs": 200
    },
    "outputSelection": {
      "*": {
        "*": [
          "evm.bytecode",
          "evm.deployedBytecode",
          "devdoc",
          "userdoc",
          "metadata",
          "abi"
        ]
      }
    },
    "remappings": []
  }
}}

Tags:
Factory|addr:0x76e9bbb66824c4b4e7b924b77788090a3fbcec3f|verified:true|block:23735606|tx:0xbc8a68dfa3d77ac3fd952f5c11546fee2e00559363b85deedadec3d02361f3ec|first_check:1762378091

Submitted on: 2025-11-05 22:28:13

Comments

Log in to comment.

No comments yet.