Exercise 2

Programming Exercise: Hallo World – Advanced Version

Behavior:

1st case: Execution without any command line argument:

Execution:     java Hallo
Output:                      Who is there?

2nd case: Execution with one command line argument:

Execution:     java Hallo Tom
Output:                      Hallo Tom!

3rd case: Execution with two command line arguments:

Execution:     java Hallo Tom Tim
Output:                      Hallo Tom and Tim!

4th case: execution with tree or more (arbitrary many) command line arguments:

Execution:     java Hallo Tracy Tom Tim
Output:                      Hallo Tracy, Tom and Tim!   

Exercise 3

Programming exercise: Matrix Product of two matrices (4x5 and 5x4 at least)

·         Matrices can be initialized from the source code.

·         Output should be printed out in a “nice” matrix format on the screen.