Created
April 9, 2022 03:17
-
-
Save alecchendev/992d0864de3abc4eab27505f07bbdb40 to your computer and use it in GitHub Desktop.
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
// get accounts | |
let accounts_iter = &mut accounts.iter(); | |
let account = next_account_info(&accounts_iter)?; | |
// modify | |
let mut account_data = account.try_borrow_mut_data()?; | |
for i in 0..account.data_len() { | |
account_data[i] = 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment