-
-
Save le0nidas/1949cdff9be84616b9f66cc22ffed2b6 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
fun saveUserTasks(userId: Int) { | |
val user = loadUser(userId) | |
println("user loaded") | |
// save loaded user | |
// pause execution | |
// resume execution | |
// restore saved user | |
val tasks = loadTasks(user) | |
println("tasks loaded") | |
// save loaded tasks | |
// pause execution | |
// resume execution | |
// restore saved tasks | |
saveTasks(tasks) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment