cryptozombieshq / cryptozombies-lesson-code Goto Github PK
View Code? Open in Web Editor NEWcryptozomebie lesson code
License: GNU General Public License v3.0
cryptozomebie lesson code
License: GNU General Public License v3.0
var web3Infura = new Web3(new Web3.providers.WebsocketProvider("wss://mainnet.infura.io/ws"));")
is there have extra symbol ")?
function getEvens() pure external returns(uint[]) {
uint[] memory evens = new uint[](5);
// On suit l'index du nouveau tableau
uint counter = 0;
// On itère de 1 à 19 avec une boucle `for` :
for (uint i = 1; i <= 10; i++) {
// Si `i` est pair...
if (i % 2 == 0) {
// On l'ajoute au tableau
evens[counter] = i;
// On incrémente le `counter` de 1 :
counter++;
}
}
return evens;
}
but need to be :
function getEvens() pure external returns(uint[]) {
uint[] memory evens = new uint[](5);
// On suit l'index du nouveau tableau
uint counter = 0;
// On itère de 1 à 10 avec une boucle `for` :
for (uint i = 1; i <= 10; i++) {
// Si `i` est pair...
if (i % 2 == 0) {
// On l'ajoute au tableau
evens[counter] = i;
// On incrémente le `counter` de 1 :
counter++;
}
}
return evens;
}
Mistake was 19 instead of 10
Hey! Just a small typo I think. The random number should be from 0 to 100 (after modulus 100). Technically, by checking rand <= 70
, that is 71% of victory probability.
I really enjoy this course! Thanks for the great work!
I just logged in from a different device in my Cryptozombies account it's showing that I have 0% progress in the advanced solidity concepts chapter which I am completely certain that I completed at least 3-4 exercises.
Hi, I'm currently doing the lesson 4 and I saw that there's a typo referring to lesson 6 that we calculated the random number but we are in lesson 4. It maybe refer to the lesson 4 that was the introduction of the random number.
This is the link: https://cryptozombies.io/en/lesson/4/chapter/10
Hello,
When you click to see the answer, the compiler is expecting to the text to be in portuguese, but when you change lessons, the sync turn all the strings in english.
Just maybe accept english or portuguese.
The compiler is complaining about the ident too... maybe a autoformat button to solve this?
great tutorial guys! thanks for sharing the knowledge!
Hi,
When will lesson 7 be released?
in Lesson-1 Chapter-8. aim is to provide logic to createZombie
function.
Exercise expects this answer:-
zombies.push(Zombie(_name, _dna));
but an alternate approach could be:-
Zombie z1 = Zombie(_name,_dna);
zombies.push(z1);
instead of expecting exact solution, it should accept this approach as well, later on student will self realize the fact of doing the same thing in one line.
This link is broken.. Just a heads up, this link seems to go to a code page - no info shown.
https://share.cryptozombies.io/
....
var web3Infura = new Web3(new Web3.providers.WebsocketProvider("wss://mainnet.infura.io/ws"));")
The code above contains a syntax error. The last two characters, namely " and ), are redundant.
Hello there,
Why inside the function on line 2:
` function _createZombie(string memory _name, uint _dna) private {
uint id = zombies.push(Zombie(_name, _dna)) - 1;
emit NewZombie(id, _name, _dna);
}`
you associate zombie.push to an unsigned integer named ID. i tried to do the same on remix but i obviously had an error.
I am doing something wrong?
Lesson 12 for libra seems to lead to a blank page. I love this project and hope I'm not being a pest. thank you so much for all your guys efforts. :)
Hi !
First, thank you for this tutorial, I'm new to blockchain development and it's well explained and easy to follow.
It seems that there is a bug.
LESSON : 5
CHAPTER : 14
BUG :
When I renamed my zombie from NoName
to Jack
it duplicated as you can see on the image below with the two identical zombies on the right.
If I rename NoName again it changes Jack's name.
DON’T USE THIS
uint id = zombies.push(Zombie(_name, _dna)) — 1;
gives error in remix
USE THIS
zombies.push(Zombie(_name, _dna));
uint id = zombies.length - 1;
sincerely
Dr. Engin YILMAZ
https://github.com/CryptozombiesHQ/cryptozombies-lesson-code/blob/master/lesson-1/chapter-11/Contract.sol has pragma solidity ^0.4.25;
- the rest of the lesson uses pragma solidity >=0.5.0 <0.6.0;
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.