Template:File/Doc: Difference between revisions
Created page with "This template is used to display the content of a file, or otherwise a block of code with the context of which file it would belong to. {{file|main.py|| def main() pass if __name__ == "__main__" main() }} == Usage == <nowiki>{{file|filename|language|contents}}</nowiki> See documentation about <code><syntaxhighlight></code> for supported languages. <nowiki>{{file|main.c|c| #include <stdio.h> main( ) { printf("hello, world\n"); } }}</nowiki> == Ex..." |
No edit summary |
||
Line 1: | Line 1: | ||
This template is used to display the content of a file, or otherwise a block of code with the context of which file it would belong to. | This template is used to display the content of a file, or otherwise a block of code with the context of which file it would belong to. | ||
{{file|main.py|| | {{file|main.py|py| | ||
def main() | <nowiki> | ||
def main(): | |||
pass | pass | ||
if __name__ == "__main__" | if __name__ == "__main__": | ||
main() | main() | ||
</nowiki> | |||
}} | }} | ||