Marcin Jasion - Pragmatic DevOps
  • Tags
  • blockchain
  • ethereum
  • introduction
  • solidity
  • tutorial
Hero Image
Deploy your first blockchain contract to Ethereum

First contract - Pet owners I am learning blockchain and smarcontract. This post will be my note how I am starting my journey to blockchain technology. In this example I will create a contract for storing who is owning a Pet. Development // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; //build contract on top of Solidity >=0.8.0 and <0.9.0 contract PetOwner { mapping (string => Pet) public petOwners; struct Pet { string name; string petType; } function addPetOwner(string memory ownerName, string memory _name, string memory _petType) public { petOwners[ownerName] = Pet({name: _name, petType: _petType}); } } Put it to the Remix IDE: https://remix.

April 9, 2022 Read
Navigation
  • About
  • Skills
  • Accomplishments
  • Presentations
Contact me:
  • hello@mjasion.pl

Toha Theme Logo Toha
© 2022 Copyright.
Powered by Hugo Logo