A Pen by Odysseas Samaras on CodePen.
This file contains 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
atom-text-editor::shadow { | |
.editor-contents--private { | |
.invisible-character { | |
visibility: hidden; | |
} | |
&.has-selection { | |
.invisible-character { | |
visibility: visible; |
This file contains 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
1. Go to Sublime Text to: Tools -> Build System -> New Build System | |
and put the next lines: | |
{ | |
"cmd": ["python3", "-i", "-u", "$file"], | |
"file_regex": "^[ ]File \"(...?)\", line ([0-9]*)", | |
"selector": "source.python" | |
} | |
Then save it with a meaningful name like: python3.sublime-build |
This file contains 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
contract Bank{ | |
/*Contract that stores user balances. This is the vulnerable contract. This contract contains | |
the basic actions necessary to interact with its users, such as: get balance, add to balance, | |
and withdraw balance */ | |
mapping(address=>uint) userBalances;/*mapping is a variable | |
type that saves the relation between the user and the amount contributed to | |
this contract. An address (account) is a unique indentifier in the blockchain*/ | |
function getUserBalance(address user) constant returns(uint) { |
This file contains 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
const columns = [ | |
{ name: 'id' , index: 'id' , width: 55 }, | |
{ name: 'invdate', index: 'invdate' , width: 90 }, | |
{ name: 'name' , index: 'name asc, invdate', width: 100 }, | |
{ name: 'amount' , index: 'amount' , width: 80 , align: "right" }, | |
{ name: 'tax' , index: 'tax' , width: 80 , align: "right" }, | |
{ name: 'total' , index: 'total' , width: 80 , align: "right" }, | |
{ name: 'note' , index: 'note' , width: 150, sortable: false } | |
]; |