Difference between revisions of "CSC231 Final Exam Fall 2017"
Line 41: | Line 41: | ||
For example, zap2( "Mississippi", "ss" ) will return "Mi--i--ppi". | For example, zap2( "Mississippi", "ss" ) will return "Mi--i--ppi". | ||
− | Store | + | Store your program in a file containing zap2() and any other function you need. Your program should not contain a main function, as it will be linked with a test program that will contain main(). |
− | + | <br /> | |
− | |||
− | |||
− | |||
− | |||
=Bash Script= | =Bash Script= | ||
− | + | <br /> | |
* Write a bash script that contains a ''recursive'' function called '''fact''' that will compute the '''factorial''' of a number passed on the command line. Call this script '''funcMoodleChallenge.sh'''. | * Write a bash script that contains a ''recursive'' function called '''fact''' that will compute the '''factorial''' of a number passed on the command line. Call this script '''funcMoodleChallenge.sh'''. |