If you were in the live stream and asked some questions -> ask them again here in the comments. KZbin closed the chat :(
@maximebeaudoin40136 жыл бұрын
#1: why did it have to be JS, i'm kinda new to programming but the syntax differs to c# in some areas and i find it less intuitive. #2 why visual studio code and not visual studio? #3 would you consider creating a simple ui to implement the functionalities created here while at the same time addressing the subjet of p2p?
@andresm90515 жыл бұрын
Really good content, keep going! I would like to ask, how to create ,sign and transaction using web3 and ethererum blockchain
@senteria5 жыл бұрын
Hello there, great video, however I get result that my chain is not valid and balance is -10
@nevcheart5 жыл бұрын
@@senteria I got this as well, my error was in minePendingTransactions()..missing a couple of lines
@peopleyoumustknow13253 жыл бұрын
Very helpful
@fluffymaverick3 жыл бұрын
For anyone having -10 balance in the first run, see 8:05, he added a rewardTx object in the minePendingTransactions method and push in the pendingTransactions array. I guess he forgot to discuss about it in the video. Anyways thanks Xavier.
@TamunutonyeHart2 жыл бұрын
Thanks!
@daa822 жыл бұрын
Yup, couldn’t figure out how he got $90 since the $100 should have been a pending reward that should become part of his balance after a 2nd mining occurs. Should have been -10.
@gregorystevens51732 жыл бұрын
Gr8 catch. Thanks Alvin!
@shin4ko1312 жыл бұрын
thank you
@vsemsimpa45072 жыл бұрын
It still incorrect, as he performs the transaction first and only then he receives 100 as a reward for mining the block with the transaction that makes his balance -10. So, ideally, his addTransaction call on line 13 gets rejected, as there are not enough funds. Only after he mines the block and receives the reward, he should be able to transfer some coins.
@davidwhite42585 жыл бұрын
P2P Bro we dying for that to be implemented
@AAA-bo1uo6 жыл бұрын
Been watching youtube for YEARS now, you are literally the *_FIRST_* I *_EVER_* subscribe to! I was able to take everything from first episode in this series to this one in 1 sitting :D Short, precise and on point with an actual clean and clear code, that is scarce! I'm still having problems with signatures but that's because I never dealt with them before.. I never interacted with public and private keys directly before. I'll probably understand it as soon as I code it in myself. Most appreciated mate! Keep up the good work!
@simplyexplained6 жыл бұрын
Wow thanks a lot man! I feel honored to be the first creator you subscribed to. Keep coding & keep learning!
@Boggothefroggo321232 жыл бұрын
@@simplyexplained I keep getting the error TypeError: Transaction is not a constructor, how do I fix this?
@rfmemarian85508 ай бұрын
I loved the video. That was the best way to describe block chain to a developer. Thank you for such an effort!
@pdhakeph6 жыл бұрын
I thoroughly enjoyed this learning block chain through implementation. Thank you
@JamesFrederickstech6 жыл бұрын
this video is pure gold! thanks for doing this. im going to go back and watch all the previous videos now.
@asmrtist90584 жыл бұрын
Love your Blockchain in Javascript series. Indeed, I learned Angular JS only so I could continue with part 5 of your series.
@alonsourena_6 жыл бұрын
Excellent video, I really learned a lot, keep going bro. Hope you can keep going with this series
@v852161923 жыл бұрын
One of the best tutorials I have seen in CS learnings!
@desertfox96135 жыл бұрын
By far the best explanation of cryptocurrency technology.
@zeerobug6 жыл бұрын
Great video. Now every time you mine, you get a reward, even though there are no txs! Can't wait for chapter 5
@simplyexplained6 жыл бұрын
Hmm, this is also the case in Bitcoin I guess. Blocks are added on a steady interval and they don't have to include transactions.
@killianpinier50743 жыл бұрын
Thank you so much !! I really liked the way you organised your videos. I learned a lot thanks to you ! Keep going 😍
@Leoninmiami6 жыл бұрын
You are a stud my friend! thanks for taking the time to put this together!
@filipstamcar65536 жыл бұрын
You make transaction hash from from address, to address and amount. What is they are same in multiple transactions? Fox example if I send same amount of coins to same address multiple times?
@simplyexplained6 жыл бұрын
Aha! You're right, how silly of me! I will include a timestamp to make it unique. Thanks!
@GS-xg7sl5 жыл бұрын
Great tutorials for beginners who want to learn about this new exciting technology. Can you also do a video on Smart Contracts in this series.
@mydentalscaler34623 жыл бұрын
Thank you a lot brother! You made it easy and simple to understand! Thanks again
@vijayantpawar31375 жыл бұрын
When I run it, I got -10 and valid? False . How to fix this please reply.
@fluffymaverick3 жыл бұрын
For anyone having 90 balance but chain is false please check your minePendingTransaction method. let block = new Block(Date.now(), this.pendingTransactions, this.getLatestBlock().hash); make sure to add this.getLatestBlock().hash.
@EliteJLad2 жыл бұрын
bro thank you sooooo much
@oguzhanyesilpinar2 жыл бұрын
thank you so much
@mual776 жыл бұрын
Another excellent video!! Keep up the good work.
@Plrang6 жыл бұрын
Simply Fantastic Explained you mean
@javedahmed12766 жыл бұрын
Great stuff man. Please create videos on creating a smart contract
@tomoya06506 жыл бұрын
An interesting blockchain 101. Like it.
@applicable_simplicity5 жыл бұрын
One of the important validation is to check if the transaction is send out an amount larger than the current balance. In blockchain, how to check this validation, could you please advise?
6 жыл бұрын
Great video, the signing of transactions was a missing part in the chain. Thanks! By the way, you forgot to re-hash the second block after you changed the amount of the transaction. Hopefully it still wouldn’t be valid due to the incorrect signature at that point.
@TJ80ify5 жыл бұрын
yeah mine came out isValid == false
@GodSavetheWest5 жыл бұрын
How can that error be fixed??
@emarciobdirector2 жыл бұрын
@@GodSavetheWest I also would like to know.
@TamunutonyeHart2 жыл бұрын
yeah, i noticed it the same result, invalid
@alphansomurray65353 жыл бұрын
Good Morning, do you have a tutorial that shows how you would facilitate the block chain code to manage IoT devices like a camera?
@EduardsSilins5 жыл бұрын
You are the best! Thanx for this tuttorial...
@dinudin71333 жыл бұрын
Great explanantion, but at 17:03 i got chain false. though the balance show 90. any idea on this?
@vlaming68183 жыл бұрын
You need to add this.getLatestBlock().hash to the block variable in the minePendingTransaction function.
@sohaibsoussi90422 жыл бұрын
let block = new Block(Date.now(),this.pendingTransactions,this.getLatestBlock().hash)
@mauriciowkjhef5 жыл бұрын
Should 'fromWallet' balance be checked before pushing into pending transaction?
@simplyexplained5 жыл бұрын
Yes it should be!
@ipungdevacademy4 жыл бұрын
Thanks you are my hero
@marekczyz34835 жыл бұрын
Wow! It is really valuable content!
@miscellaneous99324 жыл бұрын
You are the best mate! Cheers!
@x0r1k3 жыл бұрын
You've left a big issue: anyone can pretend that he get a transaction from null address. That's why reward transaction should go to the current block, no to the pending list
@simplyexplained3 жыл бұрын
Yes, this was fixed on GitHub. Can't update the video though.
@vivekjain0101845 жыл бұрын
fantastic explanation!
@amritkanoi88044 жыл бұрын
Dude you are legend !
@aliharmanansari71483 жыл бұрын
Great Video, but I didn't understand that how can some Wallet send 10 coins when it has 0 balance. From where is the initial balance is coming form, and can a wallet have negative balance?
@anonymousnearseattle27883 жыл бұрын
Maybe all of Bitcoin's starting coins were purchased by the Federal Reserve! 😁
@thenoizy6 жыл бұрын
Well explained! Thanks
@cristiang47746 жыл бұрын
What is the difference between a private key and a public key? If only the private key is unique does it mean that you can send coins to multiple wallets that share the same public key at once? And if they are both unique (the private and the public keys) why do we need both and not just the public one (considering it is longer)?
@simplyexplained6 жыл бұрын
Private and public key are both unique. The public key is freely shareable with anyone. It's the address of your wallet. The private key on the other hand is used to sign transactions. It proves that the owner of the wallet is taking money out of it. It should be kept secret so only you can spend your coins.
@Sico100013 жыл бұрын
outstanding
@kinahecate91683 жыл бұрын
Thanks so much for this
@waqasiqbal35943 жыл бұрын
Where do all the transactions are actually saved in the block chain?
@shaheermohammed28656 жыл бұрын
Hello Savjee,You are really great.Your way of teaching is excellent.Still i have a doubt.I run your code and even if i don't have any balance in my wallet i am able to make a transaction and sometimes it shows negative values in balance.Can you do something to check the balance in our wallet before making transaction?
@simplyexplained6 жыл бұрын
Absolutely! There are still a lot of checks you can implement to make it better as a cryptocurrency
@christopherequin6 жыл бұрын
thank you for this new video.
@asdeq20065 жыл бұрын
why don't we need to take account of the nonce in checking the validity of the blockchain in this example? Otherwise, someone may easily tamper the data in the blockchain and re-calculate the hash of every block in the blockchain rapidly.
@ethernetwink72302 жыл бұрын
is there a library like elliptic for python??
@IQ886125 жыл бұрын
hi, thank you very much for your videos but, what is the peer library in python to that elliptic library in JS?
@janhim6 жыл бұрын
really nice ...
@jayantkhandelwal73264 жыл бұрын
Hi, I have a doubt, as we have removed the reference to previous hash when we removed addblock method, then how are we implementing a blockchain without having previous hash value?
@JaneDoe-od4ep3 жыл бұрын
I cant get the trick with the public key and the wallet address. You say the transaction isnt valid if my wallet address != public key ... ??? Like I install electrum and create a wallet with address like 'ab1d'. Then I generate a pair of keys like public: '123f' and private: 'r45t'. So 'ab1d' != '123f'. No my transactions are ever valid? Dafak?
@ailton.duarte5 жыл бұрын
How to save transation, to not lose it when de program goes down, like when u run de program, how can i save de data from a blockchain? Or the p2p network is the database, if just one is online, we will have all data save!
@lukedavitt53575 жыл бұрын
at the end of the video, shouldn't the balance be -10, since the reward would still be a pending transaction and not processed yet? ( the same reason why about 5 minutes earlier you had to mine twice to see the reawrd in your balance )
@ElChe-Ko3 жыл бұрын
Aren't you checking anywhere if the account has enough money to allow the transaction?
@alaaradwan72425 жыл бұрын
Is this package has a random function that may generate tow pairs of public and private keys with the same values ??!!
@gizemcelik62405 жыл бұрын
Hey there Savjee! i have a quick question. I am trying to understand the whole Bitcoin topic and your videos are super great. But when i am coding along i am getting an error msg that says that my block.transaction in the getBalanceOfAddress method is not iterable. i have double checked everything and its not different from your code. any ideas on where the issue is?
@simplyexplained5 жыл бұрын
Is your version of nodejs up-to-date?
@gizemcelik62405 жыл бұрын
@@simplyexplained it actually wasnt, now everything is working. thank you!
@auroraiiit57654 жыл бұрын
Kind request. i am unable to figure out why there is an error ( No signature in this transaction) even when my code is the same as here and even matches source code. have checked it several times .... pls help
@stocksandblocks96615 жыл бұрын
bitcoin is gonna change our lives. We help people to know it
@subhambanerjee63345 жыл бұрын
hey when i am running the code it shows an error that it should have from and to adrees
@iBaldie6 жыл бұрын
How do you release your code so it’s decentralised and can be used? How is this done? Great tutorials!
@simplyexplained6 жыл бұрын
Not sure I understand your question. You usually just put your code up on a website so everyone can download it. That's how all cryptocurrencies do it. They let anyone download their client from their site.
@Boggothefroggo321232 жыл бұрын
I get an error that says TypeError: Transaction is not a constructor how do I fix this?
@technologybanglavideo66965 жыл бұрын
Which IDE have you used for coding ?Please details
@kshitijvengurlekar11925 жыл бұрын
vscode
@technologybanglavideo66965 жыл бұрын
@@kshitijvengurlekar1192 if you create a video which is how to install.. Which IDE and basic running mechanism.. It will be very helpful...for windows operating system..
@kshitijvengurlekar11925 жыл бұрын
@@technologybanglavideo6696 1. I would highly recommend you to use Linux 2. There are already many videos about how to install VSCode on Windows/Linux.
@abigaildien32525 жыл бұрын
I finally got the terminal working now my testing is way off....lol
@asmrtist90584 жыл бұрын
9:39 "We want to verify that the hash of this block" - shouldn't it be "hash of this transaction"?
@SarthakGupta5 жыл бұрын
17:09 Balance: -10 Is Chain Valid: true Why???
@dillonstreator41594 жыл бұрын
I have this as well. It should be -10 because the 100 reward for mining is still in the pending transactions and will not be rewarded until the next block is successfully mined.
@victorgeorgiev40794 жыл бұрын
most likely you have an error with minePendingTransactions() and for the validation most likely you are not checking the correct lenght in isChainValid()
@incog46002 жыл бұрын
Hey when I check if the chain is valid normally it returns false. How can I fix this?
@aaryamangupta2 жыл бұрын
Yes
@sohaibsoussi90422 жыл бұрын
let block = new Block(Date.now(),this.pendingTransactions,this.getLatestBlock().hash)
@zephirusvideos3 жыл бұрын
Someone knows how can I implement the "signTransaction" method in java?
@whoamiwhoami13004 жыл бұрын
Min 4:42
@snaplu46834 жыл бұрын
forgot to add this.signature in Transaction class
@bibbidi_bobbidi_bacons11 ай бұрын
So the more pertinent danger at least with BTC are the thousands of “dormant” wallets which randomly become active when the price spikes …. lol you all know good damn well a rug pull is always ahead no matter what the asset is
@miQize3 жыл бұрын
If a null sender address is valid for a transaction, what stops users from just sending new transactions to themselves from a null address?
@fsra162 жыл бұрын
I have the same question
@ravard43362 жыл бұрын
the solution could be to add a verification that allows ONLY-ONE transaction from a null address per block so the miner will take it for himself 🤔 (I don't know if it is implemented that way in real blockchains it's just an idea)
@ArnoneWilliam2 жыл бұрын
What if someone sends 1 coin to me, and i duplicate the message of that transaction? They have already signed that transaction, so i can steal all of their coins by duplicating that transaction over and over.
@ravard43362 жыл бұрын
Like the balance of the sender some verifications seem to not be implemented to facilitate the understanding of the whole concept. a transaction is unique on the blockchain and it's defined by its hash, before adding a new transaction, miners have to go through the all ledger to ensure another transaction with the same hash does not already exist I presume
@florencebeukes2875 жыл бұрын
So “From wallet” can be anybody’s wallet?
@newsquest11695 жыл бұрын
You can build a blockchain on dpow block chain
@asmrtist90584 жыл бұрын
16:42 How does the balance of 90 make sense? Doesn't the subsequent block have to be mined for the reward to be accounted for? At least that's how my blockchain works now and I have pretty much copied your code.
@brianjianzhao32384 жыл бұрын
Hey, I am having the same issue here. I followed his implementation. Rewards transaction is not chained at the moment when it is created. It will only be push into the block and chained when next time the mining process completes. I think there is something wrong with here.
@pisanvs4 жыл бұрын
You can push the transaction to the pendingTransactions array before mining it.
@rockey90452 жыл бұрын
Can anybody tell me where the source to this presentation are?
@elsilossos6263 жыл бұрын
👏👏👏
@fungchan92162 жыл бұрын
It shows node:internal/modules/cjs/loader:936 throw err; ^ when I run in terminal, anyone know why?
@SirJul2 жыл бұрын
Did you cd src?
@jessedampare13793 жыл бұрын
I keep getting -10 when i run the code🤔
@algrinotop73406 жыл бұрын
But how do we sign it on a website
@bspanda986 жыл бұрын
Do you make a video how to fork neo.
@simplyexplained6 жыл бұрын
Probably not
@bspanda986 жыл бұрын
Simply Explained - Savjee why not it is legal and easy to held
@simplyexplained6 жыл бұрын
I don't think people should randomly fork cryptocurrencies to start their own. There is a lot of knowledge needed to maintain your own cryptocurrency. I know it's legal, but I don't think a video would be a good idea.
@bspanda986 жыл бұрын
but you need to make it one for knowledge purpose am I right
@cliffbartle37725 жыл бұрын
The same people that wrote these programs are the same or similar characters that wrote the MCAS program for the Boeing 737 Max, get my drift?? And the tax programs and all yje government programs, and we just swallow it.
@pisanvs4 жыл бұрын
And??
@lyferp5 жыл бұрын
bro you made the same code in the start as in the 3 vid
@winniepooh25332 жыл бұрын
@Simply Explained I created my own crypto from this video series, I did it for getting more into js, can I show and share it to my friends just to make them understand the working of crypto? I need your permission because I used your code to make my crypto, and I will offcourse give your channel a huge credit.
@primerib73772 жыл бұрын
Does this really work?
@simplyexplained2 жыл бұрын
It's a very basic implementation, but yes ;)
@TT-jq3kj4 жыл бұрын
sir say ec is not const help me
@michaelthedriver2424 жыл бұрын
Command Prompt: "cannot find module 'elliptic'.
@youssrakhattab53324 жыл бұрын
me too, did you find any solution for that?????
@aofeizhang87352 жыл бұрын
Am I too stupid to understand this? Learned entry level java before...
@as2692 жыл бұрын
still get balance is 0 ?!
@alendhassan63016 жыл бұрын
amazing, but why you are ignoring (nonce)? in all your videos?
@simplyexplained6 жыл бұрын
Nonce has been implemented in the first video.
@alendhassan63016 жыл бұрын
@@simplyexplained actually in the second video you did by incrementing it in mining, thank you for that, but I mean, nonce is used so the other blocks in the chain can confirm the new mined block to be able to join them in the chain, right?, I don't see this part, hopefully you understand my saying ? thanks
@simplyexplained6 жыл бұрын
Hmm I don't follow. Nonce is just used for mining and to calculate the hash of the block (AFAIK).
@mental_block5 жыл бұрын
I had a doubt, if we can see public key of others, can we not create key object using ec.keyfrompublic and then extract the private key of that person?plz reply
@simplyexplained5 жыл бұрын
No, the keyfrompublic method wont be able to extract the private key. It will just allow you to encrypt a message for the person who has the private key.