Course Hive
Search

Welcome

Sign in or create your account

Continue with Google
or
Crypto Zombies Lesson 2, Chapter 4, Require, Solidity Require Statements
Play lesson

Crypto Zombies Tutorial (Intro to Solidity) - Crypto Zombies Lesson 2, Chapter 4, Require, Solidity Require Statements

4.0 (3)
22 learners

What you'll learn

This course includes

  • 1.3 hours of video
  • Certificate of completion
  • Access on mobile and TV

Summary

Keywords

Full Transcript

In this Chapter of Crypto Zombies we look at the require statement in Solidity. Solidity require statements allow us to run a function if a condition is true. If the condition is false it will stop execution of the function and throw and error. In this specific Solidity challenge we are asked to place a requirei statement in the beginning of our createRandomZombie function. Our statement should check to make sure the current address which called ownerZombieCount, hasn't created any zombies yet. If it is there first zombie then it will allow them since they don't have any(0) yet.

Course Hive

Continue this lesson in the app

Install CourseHive on Android or iOS to keep learning while you move.

Related Courses

FAQs

Course Hive
Download CourseHive
Keep learning anywhere