Skip to content

Instantly share code, notes, and snippets.

View codemedici's full-sized avatar
:shipit:
Hack the planet

Cosimo de' Medici codemedici

:shipit:
Hack the planet
View GitHub Profile
@codemedici
codemedici / Level_0_Practice.sol
Created December 7, 2021 17:27
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.6.0+commit.26b70077.js&optimize=false&runs=200&gist=
pragma solidity 0.6.0;
contract Level_0_Practice {
bool public levelComplete;
uint8 answer;
constructor() public {
levelComplete = false;
answer = 42;
@codemedici
codemedici / README.txt
Created November 14, 2021 09:12
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.8.0+commit.c7dfd78e.js&optimize=false&runs=200&gist=
REMIX EXAMPLE PROJECT
Remix example project is present when Remix loads very first time or there are no files existing in the File Explorer.
It contains 3 directories:
1. 'contracts': Holds three contracts with different complexity level, denoted with number prefix in file name.
2. 'scripts': Holds two scripts to deploy a contract. It is explained below.
3. 'tests': Contains one test file for 'Ballot' contract with unit tests in Solidity.
SCRIPTS
// SPDX-License-Identifier: MIT
pragma solidity ^0.6.0;
/*
* @dev Provides information about the current execution context, including the
* sender of the transaction and its data. While these are generally available
* via msg.sender and msg.data, they should not be accessed in such a direct
* manner, since when dealing with GSN meta-transactions the account sending and
* paying for execution may not be the actual sender (as far as an application
@codemedici
codemedici / 1_Storage.sol
Created July 23, 2020 09:47
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.6.6+commit.6c089d02.js&optimize=false&gist=
pragma solidity >=0.4.22 <0.7.0;
/**
* @title Storage
* @dev Store & retreive value in a variable
*/
contract Storage {
uint256 number;
@codemedici
codemedici / Level_0_Practice.sol
Last active September 10, 2020 09:46
CTF Levels
pragma solidity 0.6.0;
contract Level_0_Practice {
bool public levelComplete;
uint8 answer;
constructor() public {
levelComplete = false;
answer = 42;
@codemedici
codemedici / Powerline.md
Created February 19, 2018 14:51 — forked from mrkara/Powerline.md
Install Powerline on Debian 9 Stretch
  1. Install pip sudo apt-get install python-pip
  2. Install powerline sudo pip install powerline-status
  3. Install fonts sudo apt-get install fonts-powerline
  4. Add these lines to respective files:

.vimrc > set rtp+=/usr/local/lib/python2.7/dist-packages/powerline/bindings/vim/