This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ git remote rm origin | |
$ git remote add origin git@github.com:username/repositoryName.git | |
$ git config master.remote origin | |
$ git config master.merge refs/heads/master |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"config": { | |
"data": "market-pairs", | |
"symbol": "'USDT'", | |
"limit": 100, | |
"page": 0 | |
}, | |
"usage": { | |
"day": 6, | |
"month": 14 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"config": { | |
"data": "assets", | |
"symbol": "'USDT'", | |
"interval": "hour", | |
"data_points": 24 | |
}, | |
"usage": { | |
"day": 5, | |
"month": 13 |
This file has been truncated, but you can view the full file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"config": { | |
"data": "market", | |
"type": "fast" | |
}, | |
"usage": { | |
"day": 1, | |
"month": 1 | |
}, | |
"data": [ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: UNLICENSED | |
pragma solidity 0.8.18; | |
contract Level_2_Solution { | |
function solution(uint256[10] calldata unsortedArray) | |
external pure returns (uint256[10] memory) { | |
uint256[10] memory sortedArray = unsortedArray; | |
if(sortedArray[0] > sortedArray[8]) { | |
(sortedArray[0], sortedArray[8]) = (sortedArray[8], sortedArray[0]); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Share any code fast |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use super::*; | |
use super::test_utils::*; | |
pub fn wallet_with_alice() -> Wallet { | |
Wallet::new(vec![Address::Alice].into_iter()) | |
} | |
mod tests { | |
use super::*; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use super::*; | |
fn empty_wallet() -> Wallet { | |
Wallet::new(vec![].into_iter()) | |
} | |
pub fn wallet_with_alice() -> Wallet { | |
Wallet::new(vec![Address::Alice].into_iter()) | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# test ideas | |
//! - Only signed extrinsics are accepted, so you will learn signature verification. | |
//! - Basic calls for testing/learning, mainly represented in [`shared::RuntimeCall::System`]. | |
//! - Basic currency system. | |
//! - Basic staking/reserving system. | |
//! - Nonce system, to prevent replay attacks and similar issues. | |
//! - Tipping, which is there to mimic transaction fee payment. | |
//! Checks that must happen in apply phase are those that are mandatory to make sure a blockchain is | |
//! sound and safe. These include: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//! # FRAME-less Runtime | |
//! | |
//! Welcome to the `FRAME-less` exercise, the fourth edition. | |
//! | |
//! > This assignment is based on Joshy's experiment years ago to explore building a Substrate | |
//! > runtime using pure Rust. If you learn something new in this exercise, attribute it to his | |
//! > work. | |
//! | |
//! Parts of this assignment resembles the `mini_substrate` section of the pre-course material. It | |
//! is recommended to re-familiarize yourself with that if you have done it. Nonetheless, everything |
OlderNewer