19 lines
452 B
Rust
Raw Normal View History

2025-08-14 14:09:04 -03:00
use nssa_core::program::{read_nssa_inputs, write_nssa_outputs};
2025-08-10 18:59:29 -03:00
type Instruction = ();
2025-08-10 18:51:55 -03:00
fn main() {
2025-08-10 18:59:29 -03:00
let (input_accounts, _) = read_nssa_inputs::<Instruction>();
let [pre] = match input_accounts.try_into() {
Ok(array) => array,
Err(_) => return,
};
2025-08-14 14:09:04 -03:00
let account_pre = &pre.account;
let mut account_post = account_pre.clone();
account_post.balance += 1;
2025-08-14 14:09:04 -03:00
write_nssa_outputs(vec![pre], vec![account_post]);
}