In-lab Assignment

Implement both Client/Server parts of a communication such that Client will send two integers and Server will reply with the sum of those integers.

Client may take the two integers as an argument input to the program or in run-time from the user. After receiving the reply of the Server, Client will show the user final result.

Tip 1: Just modify echoServer and echoClient to complete the assignment.

Tip 2: Use sprintf() function to convert an integer to a string, and use atoi() function to convert a string to an integer.

After you finish the programs, you have to raise your hand and let the TA check you out.

 

Bonus:  In addition to summation, take the desired operation type from the user and execute it on the Server side.