Questions about this topic? Sign up to ask in the talk tab.
Difference between revisions of "Template:Code"
From NetSec
GertieUbpgdd (Talk | contribs) |
m (quick formatting fix) |
||
| (One intermediate revision by the same user not shown) | |||
| Line 5: | Line 5: | ||
=Usage= | =Usage= | ||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
Example: | Example: | ||
| Line 20: | Line 10: | ||
|text= | |text= | ||
<source lang="cpp"> | <source lang="cpp"> | ||
| + | |||
int exampleFunction(int x, int y){ | int exampleFunction(int x, int y){ | ||
int Sum = x + y; | int Sum = x + y; | ||
return Sum; | return Sum; | ||
} | } | ||
| + | |||
</source> | </source> | ||
}} | }} | ||
Latest revision as of 17:56, 27 June 2016
Usage
Example:
{{code
|text=
<source lang="cpp">
int exampleFunction(int x, int y){
int Sum = x + y;
return Sum;
}
</source>
}}
Will give you:
int exampleFunction(int x, int y){ int Sum = x + y; return Sum; } |