This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import "./LibCast.sol"; | |
contract Cast{ | |
using Arithmetic for uint; | |
using Arithmetic for Arithmetic.Workers; | |
Arithmetic.Workers aw; | |
uint tem; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
uint256 constant SALARY=20000; | |
struct Workers{ | |
uint8 count; | |
string name; | |
} | |
library Arithmetic{ | |
function add(uint a,uint b) internal pure returns(uint){ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//SPDX-License-Identifier: MIT | |
pragma solidity ^0.8.1; | |
import "./Proxiable.sol"; | |
contract ImplementationA is Proxiable { | |
address public owner; | |
uint public count; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: MIT | |
pragma solidity ^0.8.4; | |
contract Delegate { | |
address public owner; | |
constructor(address _owner) { | |
owner = _owner; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: MIT | |
pragma solidity ^0.8.4; | |
contract B { | |
uint public num; | |
address public sender; | |
uint public amount; | |
address public sender2; | |
string public name; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: MIT | |
pragma solidity ^0.8.4; | |
import "https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/token/ERC20/ERC20.sol"; | |
/// @author Casweeney Ojukwu | |
contract SavingLending is ERC20 { | |
address owner; | |
uint public constant maxTotalSupply = 10000000 * 10 ** 18; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: MIT | |
pragma solidity ^0.8.4; | |
/// @author Casweeney Ojukwu | |
contract PollingSystem { | |
/// @dev Created events for each transaction | |
event pollCreated(bool indexed status); | |
event voted(uint indexed candidateIndex); | |
event votingStarted(bool indexed _votingOpened); | |
event votingStopped(bool indexed _votingOpened); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: MIT | |
pragma solidity ^0.8.4; | |
contract EthereumWallet { | |
address owner; | |
constructor() { | |
owner = msg.sender; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: MIT | |
pragma solidity ^0.8.4; | |
contract Multisend { | |
address owner; | |
constructor() { | |
owner = msg.sender; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: UNLICENSED | |
pragma solidity ^0.8.9; | |
import "./IERC20.sol"; | |
contract swap{ | |
IERC20 token; | |
struct Order{ | |
address _to; |