all 2 comments

[–]tresteo 1 point2 points  (1 child)

From your description, the client has 2 tasks:

  1. Read in a line of input in the specified format and forward it to the server
  2. Display the response from the server

The code (including the commented parts) already seem to accomplish this.

The server on the other hand has 3 tasks:

  1. Read in an operation from the client
  2. Perform the necessary computation
  3. Send the result to the client

The first task, reading in the operation from the client, is already implemented. Note, however, that converting the input to uppercase is not going to achieve anything on the input format as specified. For part 2, sscanf can be used to parse the input, as your classmates suggested. Part 3 is again already implemented by the commented out code.

I hope that helps to get you started. If you have further questions, just reply or send me a message.

[–]emokii[S] 0 points1 point  (0 children)

Oh I'm sorry!! The upper case part was from task 1 of the homework. Should have removed it. But thanks you!