Last active
September 22, 2020 02:49
-
-
Save nelhage/813a13bd7f5adfdcfca4fb17abb1c7d6 to your computer and use it in GitHub Desktop.
A Go/C polyglot
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
// \ | |
/* | |
#include <stdio.h> | |
int main() { | |
printf("Hello, World from C!\n"); | |
return 0; | |
} | |
#if 0 | |
//*/ | |
package main | |
import "fmt" | |
func main() { | |
fmt.Println("Hello, World from Go") | |
} | |
// \ | |
/* | |
#endif | |
//*/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment