snippet logic on cheatsheet