I hereby claim:
- I am skymanone on github.
- I am skymanone (https://keybase.io/skymanone) on keybase.
- I have a public key ASBQRqppoX6tTqEnj8bkHUYd4bM1KtP6RfwKw-H_J5CuIwo
To claim this, I am signing this object:
cast send <contract> "store(uint256 num)" "1" --unlocked --from 0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266 | |
cast call <contract> "retrieve()" |
I hereby claim:
To claim this, I am signing this object:
use std::fmt::format; | |
use parity_scale_codec::{ Encode, Decode}; | |
use sp_core::{H256, H512, Pair}; | |
use sp_core::sr25519::{Signature}; | |
fn main() { | |
let print_string = generate("//Alice", Vote::Yes); | |
println!("Alice - Yes - {}", fm(print_string)); |
//! This is minimal Merkle tree implementation with proof checking | |
use std::{ | |
collections::hash_map::DefaultHasher, | |
hash::{Hash, Hasher}, | |
}; | |
fn main() { | |
let s = ""; | |
let h = calculate_merkle_root("Trust me, bro!"); |
use parity_scale_codec::{ Encode, Decode}; | |
use sp_core::{H256, H512, Pair}; | |
type Salt = u8; | |
const SALT: Salt = 5u8; | |
#[derive(Encode, Decode, Debug, PartialEq, Eq, Clone)] | |
pub struct BasicExtrinsic { | |
operation: Operation, |
//! In Module 1, we discussed Block ciphers like AES. Block ciphers have a fixed length input. | |
//! Real wold data that we wish to encrypt _may_ be exactly the right length, but is probably not. | |
//! When your data is too short, you can simply pad it up to the correct length. | |
//! When your data is too long, you have some options. | |
//! | |
//! In this exercise, we will explore a few of the common ways that large pieces of data can be broken | |
//! up and combined in order to encrypt it with a fixed-length block cipher. | |
//! | |
//! WARNING: ECB MODE IS NOT SECURE. | |
//! Seriously, ECB is NOT secure. Don't use it irl. We are implementing it here to understand _why_ it |
//alias a complex type for cleaner code | |
pub type Link = Option<Box<Node>>; | |
#[derive(Clone, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)] | |
pub struct Node { | |
value: i8, | |
left_node: Link, | |
right_node: Link, | |
} | |
impl Node { |
I hereby claim:
To claim this, I am signing this object:
using System; | |
using System.Threading; | |
namespace threadTest | |
{ | |
class Program | |
{ | |
static void Main(string[] args) | |
{ | |
//Let's create a dedicated thread to demmonstarte that the whole process can be done inside another thread |
{ | |
//just copy paste in .vscode/tasks.json | |
//run by pressing cmd+shift+p | |
"version": "2.0.0", | |
"tasks": [ | |
{ | |
"label": "build", | |
"group": "build", | |
"command": "msbuild", | |
"type": "process", |