Content deleted Content added
←Created page with 'Different '''Command-line argument parsing''' methods are used by different programming languages to parse command-line arguments. ==Programming languages=...' |
No edit summary |
||
Line 4:
===C===
{{main|C_syntax#Command-line_arguments}}
C uses <code>argv</code> to process command-line arguments.<ref>http://publications.gbdirect.co.uk/c_book/chapter10/arguments_to_main.html</ref>
===Java===
An example of [[Java (programming language)|Java]] argument parsing would be:
<source lang="java">
public class Echo {
public static void main (String[] args) {
for (String s: args) {
System.out.println(s);
}
}
}
</source>
===PHP===
|