Skip to content

yashithac618/web3-activity-1

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

63 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Web3 Activity – Voting Contract Assignment

📌 Overview

In this assignment, you will create a Voting Smart Contract, deploy it on any Ethereum test network using Remix (preferably using MetaMask), and submit your work through a Pull Request (PR) on GitHub.
You will also create a folder named with your roll number inside your respective branch.


🧾 Task Requirements

✅ 1. Create a Voting Smart Contract

Your smart contract should include at least the following features:

  • Ability to add candidates
  • Ability to vote for a candidate
  • Prevent double voting
  • Ability to view total votes for each candidate

🚀 Deployment Steps (Remix + MetaMask)

1️⃣ Write the Contract on Remix

2️⃣ Compile the Contract

  • Open the Solidity Compiler tab

  • Select compiler version 0.8.20 or above

  • Click Compile Voting.sol

3️⃣ Deploy the Contract (MetaMask Recommended for Bonus)

  • Go to Deploy & Run Transactions

  • (Bonus) Select environment: Injected Provider – MetaMask

  • (Bonus) Switch MetaMask to a test network (Sepolia / Holesky)

  • Click Deploy

⭐ Bonus Points: Deployment done through MetaMask instead of Remix VM.

4️⃣ Copy Your Contract Address

  • After deployment, Remix displays your contract address.
  • Copy it — you will include it in the GitHub submission.

📂 GitHub Submission Instructions

1️⃣ Create a Folder Named With Your Roll Number

  • Example:
   /your-branch-name
        /LCS20250XX
            ├── Voting.sol
            └── contract-address.txt

2️⃣ Add Required Files

  • ✔ Voting.sol

  • Your complete smart contract file.

  • ✔ contract-address.txt

  • Paste only your deployed contract address.

  • Example:

  • 0x1234abcd5678ef901234abcd5678ef90aabbccdd

3️⃣ Raise a Pull Request (PR)

  • PR Title Format:

  • Added Voting Contract -

  • PR Description Must Include:

  • Your name

  • Your roll number

  • Contract address

  • Confirmation if deployed via MetaMask (for bonus)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Solidity 100.0%