Guest User

Untitled

a guest
Dec 13th, 2018
107
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.39 KB | None | 0 0
  1. class Commander
  2. {
  3. function __construct(array $option)
  4. {
  5. switch (key($option)){
  6.  
  7.  
  8. case "one":
  9. echo "one";
  10. break;
  11.  
  12. case "two":
  13. echo "two";
  14. break;
  15.  
  16. case "help"||"h":
  17. default:
  18. echo 'Help';
  19. }}
  20.  
  21. }
  22. $option=getopt("o:t:h",["one:","two:","help:"]);
  23. new Commander($option);
Add Comment
Please, Sign In to add comment