Exercise: Program Arguments
Pull the latest version from Git. For this exercise we have prepared:
- ProgramArguments.scala: contains function stubs functions
parseArgument
,setLanguage
,setInputFile
, andsetNumPages
which need to be implemented. - ProgramArgumentsTest.scala: contains unit tests. Before using these unit tests, you have
to activate them by replacing all occurrences of
ignore
within
.
Your task is to implement functions parseArgument
, setLanguage
,
setInputFile
, and setNumPages
by using pattern matching, when
appropriate. Function parseArgument
should call the other helper functions,
depending on its arguments.