File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change 1+ 'use strict' ;
12const { Blockchain, Transaction } = require ( './blockchain' ) ;
23const EC = require ( 'elliptic' ) . ec ;
34const ec = new EC ( 'secp256k1' ) ;
45
56// Your private key goes here
6- const myKey = ec . keyFromPrivate ( '7c4c45907dec40c91bab3480c39032e90049f1a44f3e18c3e07c23e3273995cf' ) ;
7+ const myKey = ec . keyFromPrivate (
8+ '7c4c45907dec40c91bab3480c39032e90049f1a44f3e18c3e07c23e3273995cf'
9+ ) ;
710
811// From that we can calculate your public key (which doubles as your wallet address)
912const myWalletAddress = myKey . getPublic ( 'hex' ) ;
@@ -31,7 +34,9 @@ savjeeCoin.addTransaction(tx2);
3134savjeeCoin . minePendingTransactions ( myWalletAddress ) ;
3235
3336console . log ( ) ;
34- console . log ( `Balance of xavier is ${ savjeeCoin . getBalanceOfAddress ( myWalletAddress ) } ` ) ;
37+ console . log (
38+ `Balance of xavier is ${ savjeeCoin . getBalanceOfAddress ( myWalletAddress ) } `
39+ ) ;
3540
3641// Uncomment this line if you want to test tampering with the chain
3742// savjeeCoin.chain[1].transactions[0].amount = 10;
You can’t perform that action at this time.
0 commit comments