#include<string.h>
void main()
{
String s1[]={"swathi"};
string s2[]={"maddimsetti"};
s1[]=s[];
printf("%s",s1[]);
}

Answers were Sorted based on User's Feedback



#include<string.h> void main() { String s1[]={"swathi"}; string s2[]={"madd..

Answer / vivek mathan

THE ANSWER IS "ERROR";

Is This Answer Correct ?    12 Yes 1 No

#include<string.h> void main() { String s1[]={"swathi"}; string s2[]={"madd..

Answer / senthil

compilation error.

the following statement is wrong
s1[]=s[];

cannot change the value of array pointer s1

Is This Answer Correct ?    2 Yes 0 No

#include<string.h> void main() { String s1[]={"swathi"}; string s2[]={"madd..

Answer / madhavi

%d

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More C Interview Questions

Explain how can I remove the trailing spaces from a string?

0 Answers  


What is the function of multilevel pointer in c?

0 Answers  


What is the use of bit field?

0 Answers  


How can I read data from data files with particular formats?

0 Answers  


What is action and transformation in spark?

0 Answers  






a memory of 20 bytes is allocated to a string declared as char *s then the following two statements are executed: s="Etrance" l=strlen(s); what is the value of l ? a.20 b.8 c.9 d.21

4 Answers   TCS,


What is an identifier?

0 Answers  


what is the program to display your name in any color?

2 Answers   HCL,


Derive the complexity expression for AVL tree?

1 Answers  


how to print 2-D array using a single for loop?

2 Answers   Mind Tree, TCS, Value Labs,


which one is not preprocessor directive a)#if b)#elif c)#undef d)#pragma

16 Answers   Accenture, Infosys, TCS, Wipro,


Is there a way to have non-constant case labels (i.e. Ranges or arbitrary expressions)?

0 Answers  


Categories