Skip to content

Instantly share code, notes, and snippets.

@goaquin
Created April 6, 2017 14:29
Show Gist options
  • Save goaquin/f1df5f785b7df7f2224b153a1e87f0c6 to your computer and use it in GitHub Desktop.
Save goaquin/f1df5f785b7df7f2224b153a1e87f0c6 to your computer and use it in GitHub Desktop.
import java.lang.Math; // headers MUST be above the first class
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
// one class needs to have a main() method
public class HelloWorld
{
// arguments are passed using the text field below this editor
public static void main(String[] args)
{
List<String> argsList = Arrays.asList(args);
for (String argu : argsList) {
System.out.println(argu);
if(argu.contains("-cloneWeb")){
System.out.println("-cloneWeb");
}
else if(argu.contains("-cloneDolar")){
System.out.println("-cloneDolar");
}
else if(argu.contains("-password=")){
System.out.print("password");
}
else {
System.out.println("error");
System.exit(1);
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment