You are on page 1of 1

C Programming Name __________________________________ Test I: IDENTIFICATION __________1. The command use to get the reverse of a string __________ .

It is the command that co!ies a string varia"#e to another varia"#e. __________$. It is the command use to convert to u!!ercase a string. __________%. It is the command use to convert to #o&ercase a string. __________'. It is the command use get the num"er of characters of a string. __________(. It is the command use to out!ut to the screen. __________). It is the command use to &rite string to a te*t fi#e. __________+. It is the command that #oo!s for an e*act num"er of times. __________,. The command use to move the !ointer of the fi#e on the first character of the fi#e. __________1-. The command use to o!en a fi#e stream. Test II. P.O/.A0 1I023ATION: &rite the e*!ected out!ut of the fo##o&ing !rograms. 1.4 5inc#ude 6iostream.h7 5inc#ude 6string.h7 void main 84 9 FI3E :fs; char m<string=1-->; fs?fo!en8@m<fi#e.t*tABArA4; re&ind8fs4; &hi#e8fgets8m<stringB 1--B fs449 cout66m<string; CC Test III PO/.A00IN/: 1.4 Create a !rogram that &i## #et <ou in!ut Duantit<B !roduct nameB !rice and save them to a te*t fi#e named @!roduct.t*tA. .4 Create a !rogram that &i## dis!#a< the contents of a te*t fi#e on to the screen. 0<fi#e.t*t This is the contents of m<fi#e.t*t This is the ne*t #ine on the te*t fi#e This is the third #ine This is the end of the #ine

You might also like