-
Notifications
You must be signed in to change notification settings - Fork 0
/
token.sol
22 lines (21 loc) · 1.85 KB
/
token.sol
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
//Certainly! Here's an assignment question tailored around the provided Solidity smart contract: ---
// Assignment: DAO Smart Contract Development**
// Your task is to design a Decentralized Autonomous Organization (DAO) using the provided Solidity smart contract structure named `DAO`. This DAO will allow investors to contribute funds, create proposals, vote on proposals, and execute them. Implement the following functionalities:
// 1. Contribution:
// - Develop a function that allows investors to contribute Ether to the DAO in exchange for shares. Ensure that contributions are only allowed within a specified contribution time limit.
// 2. Redeem Shares:
// - Implement a function that allows investors to redeem a specific amount of their shares and withdraw the corresponding Ether.
// 3. Transfer Shares:
// - Create a function to enable investors to transfer their shares to another address within the DAO.
// 4. Proposal Creation:
// - Develop a function allowing the manager to create proposals, specifying a description, requested amount, and recipient address.
// 5. Voting on Proposals:
// - Implement a voting system where investors can vote on proposals created by the manager. Ensure investors can vote only once for each proposal.
// 6. Executing Proposals:
// - Develop a function that allows the manager to execute a proposal. Ensure the proposal can only be executed if it receives the required quorum (specified as a percentage of total shares).
// 7. Data Retrieval:
// - Create functions to retrieve:
// - List of proposals created within the DAO. - List of investors in the DAO.
// Ensure proper access control is enforced for manager-specific functionalities and investor-specific actions. The contract should be initialized with predefined values for contribution time, vote time, and quorum.