Updated snippets for C and Python