Skip to content

Instantly share code, notes, and snippets.

@jacklynrose
Last active August 29, 2015 14:01
Show Gist options
  • Save jacklynrose/60e376e238610d6148b5 to your computer and use it in GitHub Desktop.
Save jacklynrose/60e376e238610d6148b5 to your computer and use it in GitHub Desktop.
Hello {{name}} in C
#include <stdio.h>
#include <string.h>
int main(int argc, char *argv[])
{
char hello[80];
strcpy(hello, "Hello ");
if (argc > 1)
{
puts(strcat(hello, argv[1]));
}
else
{
puts(hello);
}
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment