APJ ABDUL KALAM TECHNOLOGICAL UNIVERSITY Previous Years Question Paper & Answer

Course : B.Tech

Semester : S1 and S2

Year : 2018

Term : MARCH

Branch : BIOTECHNOLOGY

Scheme : 2015 Full Time

Course Code : CS 100

Page:12





PDF Text (Beta):

text file-

2. data is in the rm of alphabets and numera$
3. accessing time 15 more as compared to binary files
4. human readable files.

5. consume more space in memory than binary files.

1. extension is .txt binary file-

1. extension is .doc

2. data is inthe form of 0 and 1.

3. accessing time is less as compared to text files.
4. human unreadable files.

5. consume less space in memory than text files.

13.

a)strlen() . strlen() function returns the length of the string. strlen() function returns integer value.

Example: char *str = "Learn ©
Online"; int strLength;
strLength = strlen(str); //strLength contains the length of the string i.e. 14

char *str="LearnC Online"; ராம்‌
strLength;

strLength = strlen(str); | //strLength contains the length of the string 1.6. 14 0) strcpy() = strcpy()
function is used to copy one string to another. The Destination_String should be a variable and
Source_String can either be a string constant or a variable.

Syntax:

strcpy(Destination_String,Source_String);
Example: char *Destination_String;

char *Source_String = "Learn C Online";
strcpy(Destination_String,Source_String); = printf("%s",
Destination_String);

char *Destination_String;

Similar Question Papers