Privacy and Security Notice

Archived Messages for C_CLASS98@cebaf.gov: CORRECTED Assignment

CORRECTED Assignment

Dr. C. Allen Butler (allen@va.wagner.com)
Tue, 17 Mar 1998 10:06:12 -0800 (PST)

Forgot to specify review prblems for Chapter 6.

# Chapter Review Problems Problem to Submit Due Date
-- ------- -------------- ----------------- -------
1. 4 None 26 03/03/98
2. 2 19 - 24 24 03/05/98
3. 3 1,3,5,22,23,25 3 03/12/98
4. 4 13,22,23,29,31 email 03/19/98
(cont) 5 5,15,17,26
5. 5 22 03/26/98
(cont) 6 10,11,12,17,24 see below 03/26/98

Assignment 5

1. Write a string handling function whose prototype is
char *reverse (char*);
The function will use calloc() to allocate memory for a new string of
the same size as the input string and will return a pointer to this
string which will consist of the original string in the r everste order.
For example, sif the input to the function is "This is a test." the
function will return a pointer to the string ".tset a si sihT".

2. Write a string handling function whose prototype is
void in_place_reverse (char *);
The function will also reverse the input string, but will do so "in
place". That is the function should modify the input string so that the
string now has the characters reversed.

3. Write a main program which tests each of the two functions written
above.