HW4 - MAE 9: Homework #4, Fall 2006 Due on Thursday,...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
MAE 9: Homework #4, Fall 2006 Due on Thursday, October 19, before 9:00 pm Use the program skeleton below starting with #include <stdio.h> as the starting point. Declare in main() char message[111]; (a) Print a blank line and a message "Homework 4:" and a blank line. Add the necessary statements to the switch cases. In case 1 for the switch (b) print a blank line, a line with the message:"Part I:" and a blank line. (c) Prompt the user to enter a text message from the keyboard and accept a text from the keyboard by using gets(). (d) Print the original message on the screen. (e) Find the number of characters in the message by using strlen() and print the message in the reverse order. For example, "ROSIE IS CUTE!" becomes "!ETUC SI EISOR". In case 2 for the switch (f) print a blank line, a line with the message:"Part II:" and a blank line. (g) Print a message: "Series evaluation: x^n/n! from n=0 to n=n_end.\n" and a blank line.
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 05/22/2008 for the course MAE 9 taught by Professor Lubarda during the Fall '07 term at UCSD.

Page1 / 3

HW4 - MAE 9: Homework #4, Fall 2006 Due on Thursday,...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online