Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
45 changes: 45 additions & 0 deletions mover/nguyenhoangphuquy/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
## Basic Information
- Sui Wallet Address: `0xed135194a6692ddf194ce39d06d8af11382ef01e3353a2f1a355aef82c1246f8`
> First-time participants must complete the registration of the wallet address through the first task to have it merged. You should use this address for subsequent tasks. We will also use this address to credit the learning rewards.
- Github: `nguyenhoangphuquy`

## Personal Introduction
- Work Experience: `student`
- Tech Stack: `JavaScript`, `Move`, `Solidity`
> I am a final-year student majoring in software engineering. For most of my studies, I focused on Web2 development—building RESTful APIs, working with databases, and optimizing server-side performance. But I always felt like something was missing. Web3 opened up a new way of thinking about data, ownership, and security, and when I discovered Sui, it all started to make sense.Move is different from any programming language I have worked with before, but it forces me to think carefully about how resources are managed. Right now, I am building my first DeFi project on Sui, which aims to create a lending platform with enhanced security guarantees. My ambition is to launch a startup in the Web3 space and contribute to the development of financial tools that are accessible to everyone.
- Discord: `Edward Dev`

## Tasks

### 01 hello move
- [x] Sui CLI Version: sui 1.42.0
- [x] Sui Wallet Screenshot: ![](images/sui_wallet.png)
- [x] Package ID:0x2eb0eac8b29ac4acfe640f86ce7bc9ad4656f2617b3a87dffdeb5d0cd0fce4b1
- [x] Package ID's Screenshot from Explorer: ![](images/packageid.png)

### 02 move coin
- [x] `My Coin` Package ID:0xeaa490ff93199bf56ddfdb230751225662c7abf1cc36c698d4fffedfd94ea266
- [x] `Faucet Coin` Package ID:0x717301f818bc0b613ab4937ce30afb3eecd3aebfb791df3fec1c80edddffdd68
- [x] Transfer `My Coin` hash:B5xm12peBr83pA8kriJMUnVTN7GcWxqvJQWYbZyz8Evs
- [x] `Faucet Coin` address 1 mint hash:BdJDDyade7CyV2RMUN4rAxe9SawdTcQZiTbaPTJKbEwW
- [x] `Faucet Coin` address 2 mint hash:CZKCmVbAfjpqcruHWDADDLPNhss5iZceNVm5Q5XgDzPB

### 03 move nft
- [x] NFT Package ID:0x7ee8c09761d4ecadf02446920063db5f9edce4f5e936e00ba6aa3f5213a39d0a
- [x] NFT Object ID:0xc552e97f2749bbb7b35d82232bf81fdec2dbabaf5964a4f56a4e5dbc6199ccf2
- [x] Transfer NFT hash:Fqr9gr95hyT8W5Qs8oecCCbYau8YVgQQePN6FTKY7zdV
- [x] NFT's Screenshot from Explorer: ![](images/nft.png)

### 04 move game
- [x] Game Package ID:0x45b93f73b0f1ecc589cee17c3c6dbe4b5d62fab96ff815505edcd06b83070757
- [x] Deposit Coin Hash:Df1brat8VwQKLEbdTkTDra6MAkkGQen19aaVriEa3Tdr
- [x] Withdraw Coin Hash:CsgYJcS7TBqdG14rAjeAeS8v67rFbtS7WUBe9eDkmSE7
- [x] Play Game Hash:2qryo7y1gQz4KYJCcU6vVCim4cq4h1WffXU4pRdv7ijC

### 05 move swap
- [x] Swap Package ID:0x3a9db2b8f454b1ddb72c6b7ccf00f3e9e10f84d9fa2bf7a256951f7fcb42851a
- [x] Call Swap Coin A -> Coin B hash:FejGNQBP5XhK8xZy9CWb7ARicjqPkGtaqgBSYRNMuNqE
- [x] Call Swap Coin B -> Coin A hash:47GcDKA5jYsmpdQYuXKXgyqawsQMxnncJxpHT5TTw2hR

### 06 dapp-kit SDK PTB
- [x] Save Hash:BGFQiZbpSZXvXN6grRGWapRMDUqkchThexmwecW9hLey
Empty file.
Empty file.
1 change: 1 addition & 0 deletions mover/nguyenhoangphuquy/code/task1/hello_move/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
build/*
34 changes: 34 additions & 0 deletions mover/nguyenhoangphuquy/code/task1/hello_move/Move.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# @generated by Move, please check-in and do not edit manually.

[move]
version = 3
manifest_digest = "8B7DC3EDF1D81F9E2D46D8251E70F4B8D7097878F02438454C30AEF9F05D81D0"
deps_digest = "F8BBB0CCB2491CA29A3DF03D6F92277A4F3574266507ACD77214D37ECA3F3082"
dependencies = [
{ id = "Sui", name = "Sui" },
]

[[move.package]]
id = "MoveStdlib"
source = { git = "https://github.com/MystenLabs/sui.git", rev = "framework/testnet", subdir = "crates/sui-framework/packages/move-stdlib" }

[[move.package]]
id = "Sui"
source = { git = "https://github.com/MystenLabs/sui.git", rev = "framework/testnet", subdir = "crates/sui-framework/packages/sui-framework" }

dependencies = [
{ id = "MoveStdlib", name = "MoveStdlib" },
]

[move.toolchain-version]
compiler-version = "1.42.0"
edition = "2024.beta"
flavor = "sui"

[env]

[env.testnet]
chain-id = "4c78adac"
original-published-id = "0x2eb0eac8b29ac4acfe640f86ce7bc9ad4656f2617b3a87dffdeb5d0cd0fce4b1"
latest-published-id = "0x2eb0eac8b29ac4acfe640f86ce7bc9ad4656f2617b3a87dffdeb5d0cd0fce4b1"
published-version = "1"
37 changes: 37 additions & 0 deletions mover/nguyenhoangphuquy/code/task1/hello_move/Move.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
[package]
name = "hello_move"
edition = "2024.beta" # edition = "legacy" to use legacy (pre-2024) Move
# license = "" # e.g., "MIT", "GPL", "Apache 2.0"
# authors = ["..."] # e.g., ["Joe Smith (joesmith@noemail.com)", "John Snow (johnsnow@noemail.com)"]

[dependencies]
Sui = { git = "https://github.com/MystenLabs/sui.git", subdir = "crates/sui-framework/packages/sui-framework", rev = "framework/testnet" }

# For remote import, use the `{ git = "...", subdir = "...", rev = "..." }`.
# Revision can be a branch, a tag, and a commit hash.
# MyRemotePackage = { git = "https://some.remote/host.git", subdir = "remote/path", rev = "main" }

# For local dependencies use `local = path`. Path is relative to the package root
# Local = { local = "../path/to" }

# To resolve a version conflict and force a specific version for dependency
# override use `override = true`
# Override = { local = "../conflicting/version", override = true }

[addresses]
hello_move = "0x0"

# Named addresses will be accessible in Move as `@name`. They're also exported:
# for example, `std = "0x1"` is exported by the Standard Library.
# alice = "0xA11CE"

[dev-dependencies]
# The dev-dependencies section allows overriding dependencies for `--test` and
# `--dev` modes. You can introduce test-only dependencies here.
# Local = { local = "../path/to/dev-build" }

[dev-addresses]
# The dev-addresses section allows overwriting named addresses for the `--test`
# and `--dev` modes.
# alice = "0xB0B"

Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
module hello_move::hello {

use sui::object::{Self, UID};
use std::string::{Self, String};
use sui::tx_context::{Self, TxContext};
use sui::transfer;

public struct Hello_nguyenhoangphuquy has key {
id: UID,
name: String,
}

public entry fun say_hello_to_nguyenhoangphuquy(ctx: &mut TxContext) {
let hello_world = Hello_nguyenhoangphuquy {
id: object::new(ctx),
name: string::utf8(b"Hello Nguyen Hoang Phu Quy"),
};
transfer::transfer(hello_world, tx_context::sender(ctx));
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
/*
#[test_only]
module hello_move::hello_move_tests;
// uncomment this line to import the module
// use hello_move::hello_move;

const ENotImplemented: u64 = 0;

#[test]
fun test_hello_move() {
// pass
}

#[test, expected_failure(abort_code = ::hello_move::hello_move_tests::ENotImplemented)]
fun test_hello_move_fail() {
abort ENotImplemented
}
*/
Empty file.
1 change: 1 addition & 0 deletions mover/nguyenhoangphuquy/code/task2/faucet_coin/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
build/*
34 changes: 34 additions & 0 deletions mover/nguyenhoangphuquy/code/task2/faucet_coin/Move.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# @generated by Move, please check-in and do not edit manually.

[move]
version = 3
manifest_digest = "F8CFCF256E2F1BB7CD401C27799A09C40777C5C100F0DFA253E86DD7F0D4ED1B"
deps_digest = "F8BBB0CCB2491CA29A3DF03D6F92277A4F3574266507ACD77214D37ECA3F3082"
dependencies = [
{ id = "Sui", name = "Sui" },
]

[[move.package]]
id = "MoveStdlib"
source = { git = "https://github.com/MystenLabs/sui.git", rev = "framework/testnet", subdir = "crates/sui-framework/packages/move-stdlib" }

[[move.package]]
id = "Sui"
source = { git = "https://github.com/MystenLabs/sui.git", rev = "framework/testnet", subdir = "crates/sui-framework/packages/sui-framework" }

dependencies = [
{ id = "MoveStdlib", name = "MoveStdlib" },
]

[move.toolchain-version]
compiler-version = "1.42.0"
edition = "2024.beta"
flavor = "sui"

[env]

[env.testnet]
chain-id = "4c78adac"
original-published-id = "0x717301f818bc0b613ab4937ce30afb3eecd3aebfb791df3fec1c80edddffdd68"
latest-published-id = "0x717301f818bc0b613ab4937ce30afb3eecd3aebfb791df3fec1c80edddffdd68"
published-version = "1"
37 changes: 37 additions & 0 deletions mover/nguyenhoangphuquy/code/task2/faucet_coin/Move.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
[package]
name = "faucet_coin"
edition = "2024.beta" # edition = "legacy" to use legacy (pre-2024) Move
# license = "" # e.g., "MIT", "GPL", "Apache 2.0"
# authors = ["..."] # e.g., ["Joe Smith (joesmith@noemail.com)", "John Snow (johnsnow@noemail.com)"]

[dependencies]
Sui = { git = "https://github.com/MystenLabs/sui.git", subdir = "crates/sui-framework/packages/sui-framework", rev = "framework/testnet" }

# For remote import, use the `{ git = "...", subdir = "...", rev = "..." }`.
# Revision can be a branch, a tag, and a commit hash.
# MyRemotePackage = { git = "https://some.remote/host.git", subdir = "remote/path", rev = "main" }

# For local dependencies use `local = path`. Path is relative to the package root
# Local = { local = "../path/to" }

# To resolve a version conflict and force a specific version for dependency
# override use `override = true`
# Override = { local = "../conflicting/version", override = true }

[addresses]
faucet_coin = "0x0"

# Named addresses will be accessible in Move as `@name`. They're also exported:
# for example, `std = "0x1"` is exported by the Standard Library.
# alice = "0xA11CE"

[dev-dependencies]
# The dev-dependencies section allows overriding dependencies for `--test` and
# `--dev` modes. You can introduce test-only dependencies here.
# Local = { local = "../path/to/dev-build" }

[dev-addresses]
# The dev-addresses section allows overwriting named addresses for the `--test`
# and `--dev` modes.
# alice = "0xB0B"

Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
module 0x0::faucet_coin {

use std::option::{Self, some};
use sui::coin::{Self, TreasuryCap, Coin};
use sui::transfer;
use sui::tx_context::{Self, TxContext};
use sui::url::{Self};

public struct FAUCET_COIN has drop {}

fun init(witness: FAUCET_COIN, ctx: &mut TxContext) {
let (treasury, metadata) = coin::create_currency(
witness,
2,
b"nguyenhoangphuquy",
b"NGUYENHOANGPHUQUY FAUCET",
b"DAY LA COIN FAUCET CUA NGUYENHOANGPHUQUY",
some(url::new_unsafe_from_bytes(b"https://avatars.githubusercontent.com/u/198892827?v=4")),
ctx
);
transfer::public_freeze_object(metadata);
transfer::public_share_object(treasury);
}

public entry fun mint(treasury: &mut TreasuryCap<FAUCET_COIN>, amount: u64, recipient: address, ctx: &mut TxContext)
{
coin::mint_and_transfer(treasury, amount, recipient, ctx);
}

public fun burn(treasury: &mut TreasuryCap<FAUCET_COIN>, coin: Coin<FAUCET_COIN>) {
coin::burn(treasury, coin);
}
}

Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
/*
#[test_only]
module faucet_coin::faucet_coin_tests;
// uncomment this line to import the module
// use faucet_coin::faucet_coin;

const ENotImplemented: u64 = 0;

#[test]
fun test_faucet_coin() {
// pass
}

#[test, expected_failure(abort_code = ::faucet_coin::faucet_coin_tests::ENotImplemented)]
fun test_faucet_coin_fail() {
abort ENotImplemented
}
*/
1 change: 1 addition & 0 deletions mover/nguyenhoangphuquy/code/task2/my_coin/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
build/*
34 changes: 34 additions & 0 deletions mover/nguyenhoangphuquy/code/task2/my_coin/Move.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# @generated by Move, please check-in and do not edit manually.

[move]
version = 3
manifest_digest = "0A4652D38CF3C3FDB79EC6C1C98FCFF7B2E933E12B84A1DA267DB28F66AFECE3"
deps_digest = "F8BBB0CCB2491CA29A3DF03D6F92277A4F3574266507ACD77214D37ECA3F3082"
dependencies = [
{ id = "Sui", name = "Sui" },
]

[[move.package]]
id = "MoveStdlib"
source = { git = "https://github.com/MystenLabs/sui.git", rev = "framework/testnet", subdir = "crates/sui-framework/packages/move-stdlib" }

[[move.package]]
id = "Sui"
source = { git = "https://github.com/MystenLabs/sui.git", rev = "framework/testnet", subdir = "crates/sui-framework/packages/sui-framework" }

dependencies = [
{ id = "MoveStdlib", name = "MoveStdlib" },
]

[move.toolchain-version]
compiler-version = "1.42.0"
edition = "2024.beta"
flavor = "sui"

[env]

[env.testnet]
chain-id = "4c78adac"
original-published-id = "0xeaa490ff93199bf56ddfdb230751225662c7abf1cc36c698d4fffedfd94ea266"
latest-published-id = "0xeaa490ff93199bf56ddfdb230751225662c7abf1cc36c698d4fffedfd94ea266"
published-version = "1"
37 changes: 37 additions & 0 deletions mover/nguyenhoangphuquy/code/task2/my_coin/Move.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
[package]
name = "my_coin"
edition = "2024.beta" # edition = "legacy" to use legacy (pre-2024) Move
# license = "" # e.g., "MIT", "GPL", "Apache 2.0"
# authors = ["..."] # e.g., ["Joe Smith (joesmith@noemail.com)", "John Snow (johnsnow@noemail.com)"]

[dependencies]
Sui = { git = "https://github.com/MystenLabs/sui.git", subdir = "crates/sui-framework/packages/sui-framework", rev = "framework/testnet" }

# For remote import, use the `{ git = "...", subdir = "...", rev = "..." }`.
# Revision can be a branch, a tag, and a commit hash.
# MyRemotePackage = { git = "https://some.remote/host.git", subdir = "remote/path", rev = "main" }

# For local dependencies use `local = path`. Path is relative to the package root
# Local = { local = "../path/to" }

# To resolve a version conflict and force a specific version for dependency
# override use `override = true`
# Override = { local = "../conflicting/version", override = true }

[addresses]
my_coin = "0x0"

# Named addresses will be accessible in Move as `@name`. They're also exported:
# for example, `std = "0x1"` is exported by the Standard Library.
# alice = "0xA11CE"

[dev-dependencies]
# The dev-dependencies section allows overriding dependencies for `--test` and
# `--dev` modes. You can introduce test-only dependencies here.
# Local = { local = "../path/to/dev-build" }

[dev-addresses]
# The dev-addresses section allows overwriting named addresses for the `--test`
# and `--dev` modes.
# alice = "0xB0B"

28 changes: 28 additions & 0 deletions mover/nguyenhoangphuquy/code/task2/my_coin/sources/my_coin.move
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
module 0x0::my_coin {

use std::option::{Self, some};
use sui::coin::{Self, TreasuryCap, Coin};
use sui::tx_context::{Self, TxContext};
use sui::transfer;
use sui::url::{Self};

public struct MY_COIN has drop {}

fun init(witness: MY_COIN, ctx: &mut TxContext) {
let (treasury, coinmedata) = coin::create_currency(
witness,
5,
b"nguyenhoangphuquy",
b"nguyenhoangphuquy",
b"My first coin",
some(url::new_unsafe_from_bytes(b"https://avatars.githubusercontent.com/u/198892827?v=4")),
ctx
);
transfer::public_freeze_object(coinmedata);
transfer::public_transfer(treasury, ctx.sender());
}

public entry fun mint(treasury: &mut TreasuryCap<MY_COIN>, amount: u64, recipient: address, ctx: &mut TxContext) {
coin::mint_and_transfer(treasury, amount, recipient, ctx);
}
}
Loading