New | Solidity 0.8

  Рет қаралды 11,603

Smart Contract Programmer

Smart Contract Programmer

Күн бұрын

Пікірлер: 31
@ChalkusAurelius
@ChalkusAurelius 2 жыл бұрын
Really appreciate all these quick starter vids on solidity concepts! Top man for taking the time to create 👍
@supadrasta
@supadrasta 2 жыл бұрын
Clear and crisp explanation. Thank you.
@MrCoreyTexas
@MrCoreyTexas 4 ай бұрын
In my testing, I found out you can deploy 1 or more Account contracts for the same user, or you can create different Account contracts for different users, as long as there's enough Wei in the AccountFactory to create them. You could also add a fallback/receive to AccountFactory to reload it with more Wei.
@Bruhne
@Bruhne Жыл бұрын
Got it!
@mizo7627
@mizo7627 2 жыл бұрын
Hi , in the blockchain if we deployed the AccountFactory first , how will the contract Account be visible to us if it is not deployed yet?
@zachz6620
@zachz6620 2 жыл бұрын
Thanks again SCP for all this great content. May i ask... with this new contract method you've shown us here.... does this mean you can actually create a copy any contract that is publicly deployed on the ETH blockchain? For example, if wanted to create a "copy of the uniswap contract" i can do it by creating the contract you just showed us and then i would actually be able to see if and use it? Just trying to envision a practical application of this.
@ismaila3347
@ismaila3347 2 жыл бұрын
Thanks for the video! quick question, why is the function createAccount in AccountFactory contract marked as external and not as public? thank you!
@smartcontractprogrammer
@smartcontractprogrammer 2 жыл бұрын
You tell me. Watch the video about visibility
@ismaila3347
@ismaila3347 2 жыл бұрын
@@smartcontractprogrammer makes sense , another question, why do we declare constructors as public even though we only access them externally? do you agree that we should declare them as external? am I missing something? :)
@smartcontractprogrammer
@smartcontractprogrammer 2 жыл бұрын
Solidity 0.8, no visibility is declared for constructor
@NishantSingh-zx3cd
@NishantSingh-zx3cd 2 жыл бұрын
Good work, thanks
@NishantSingh-zx3cd
@NishantSingh-zx3cd 2 жыл бұрын
what happens if we omit 'new' and keep the rest of the code the same?
@nicolasruiz5542
@nicolasruiz5542 2 жыл бұрын
Awesome video!! I just have a question, What is a real use case for this kind of contract ??
@smartcontractprogrammer
@smartcontractprogrammer 2 жыл бұрын
contracts that deploy contracts Uniswap V2 and V3
@shubhzdev4905
@shubhzdev4905 10 ай бұрын
shouldn't value:msg.value instead of 111?
@pythusiast4701
@pythusiast4701 Жыл бұрын
In line number 18# why are we not using any visibility specifier like public,private etc. ? Something like => `Account public account = new Account(_owner)`
@MrCoreyTexas
@MrCoreyTexas 4 ай бұрын
I don't think public/private apply to contracts? Good question, shows you are thinking about the overall syntax of Solidity (it can be confusing, too, which goes first, public or payable?) Basically every contract that is deployed is out there on the blockchain for anyone to see, so they are all public in that sense.
@Ts2pc
@Ts2pc 2 жыл бұрын
The third time , now having a better understanding. Very good example. One question, since the Factory has deployed a new Account(the new contract), so is it still necessary to deploy the new Account by the new contract address?
@MrCoreyTexas
@MrCoreyTexas 4 ай бұрын
I'm not exactly sure what you mean, but I think if you were to do this on the mainnet or testnet, the Account contract is actually there on the blockchain as soon as you call createAccount in AccountFactory, it's just that when you "Deploy at Address" in Remix, it allows it to appear in that left hand window. When I graduate from "Remix school" where we're all starting, I'll test that out.
@stevekimani.111
@stevekimani.111 Жыл бұрын
can someone please explain why when we create the account contract using accountFactory the contract account its balance is still zero or is it something i am doing wrong
@MrCoreyTexas
@MrCoreyTexas 4 ай бұрын
No, you're OK, the account balance of AccountFactory is initially 0 wei, but when you call createAccount you send wei with THAT transaction. So the first tx deploys Account Factory but sends 0 wei and then the second tx calls AccountFactory.createAccount() but you have to send wei with it (or otherwise that tx fails and reverts)
@zulfiqar7967
@zulfiqar7967 2 жыл бұрын
I need to learn Blockchain from scratch., From where should i start..? And can u share any roadmap..?
@smartcontractprogrammer
@smartcontractprogrammer 2 жыл бұрын
I've made a video, search roadmap
@muzingnimzing438
@muzingnimzing438 2 жыл бұрын
Hello sir, please what if i add another account, how do i push it into that array? thanks
@smartcontractprogrammer
@smartcontractprogrammer 2 жыл бұрын
myArray.push(my address)
@Ts2pc
@Ts2pc 2 жыл бұрын
The "At Address button" is not enabled?
@moustafaezz9158
@moustafaezz9158 2 жыл бұрын
Same problem
@РоманКоротков-з3ц
@РоманКоротков-з3ц 2 жыл бұрын
Plz change Subtites in English.
@smartcontractprogrammer
@smartcontractprogrammer 2 жыл бұрын
It's auto generated by KZbin
Delegatecall | Solidity 0.8
9:26
Smart Contract Programmer
Рет қаралды 25 М.
Access Control | Solidity 0.8
11:40
Smart Contract Programmer
Рет қаралды 14 М.
Trick-or-Treating in a Rush. Part 2
00:37
Daniel LaBelle
Рет қаралды 45 МЛН
How To Choose Mac N Cheese Date Night.. 🧀
00:58
Jojo Sim
Рет қаралды 71 МЛН
LangGraph Crash Course with code examples
39:01
Sam Witteveen
Рет қаралды 86 М.
Beginners Should Think Differently When Writing Golang
11:35
Anthony GG
Рет қаралды 120 М.
ZIG | Ep1 | Introduction
20:18
Code Guild
Рет қаралды 10 М.
Crowd Fund | Solidity 0.8
20:58
Smart Contract Programmer
Рет қаралды 13 М.
Keccak256 Hash Function | Solidity 0.8
8:41
Smart Contract Programmer
Рет қаралды 16 М.
Why aren't you using Fastify? Or Koa? Or NestJS?
9:58
Maximilian Schwarzmüller
Рет қаралды 64 М.
Verify Signature | Solidity 0.8
14:50
Smart Contract Programmer
Рет қаралды 31 М.
Don't Use Websockets (Until You Try This…)
6:46
Code With Ryan
Рет қаралды 320 М.
Solidity in 100 Seconds
2:22
Fireship
Рет қаралды 432 М.
Call Other Contracts | Solidity 0.8
7:51
Smart Contract Programmer
Рет қаралды 22 М.