If u want to initialize an array u will have to initialize it where it is declared. u cant initialze it later.so char arr[6][6]={"rotor","motor","peter","mater","water"}; is the correct way.
defmer
Feb 12th, 2007
First of all supposed array "a" does not have a type defined...so that itself will give out compilation errors.
You need not write #include, but at the time of compilation you need to compile with options which direct compiler to include files in the provided directory. in gcc it is done by -I option.
#include"stdio.h" will only compile standard input output function
Bharti
Mar 15th, 2007
#include : will search for the file in the specified directory#include"filename" : will search for the file in current directory as well as specified directory
Static int variable are accessed only inside the file where it is defined. Thus we can have same variable name in 2 files if the variable is defined as static. The scope of the va...
Lint was the name given to a tool flagged suspicious and non-portable constructs (ie, likely to be bugs) in C language source code. Ans is 4} tool for analysing c program
gaurav_gangwar9
Mar 17th, 2007
I think ans is 4, as? this is used for analysing source code, However it can be used for flagging bugs
No difference. const either refers to the item on it's left, or if there is no item on the left, to the item on the right. So both lines declare s as a variable pointer to a constant character.
Integer pointertypedef Is not the same as #define, meaning typedef does not make sure text is replaced before the compiler kicks in. It's a type definition, meaning everything declared as ptr will be an integer pointer.
kiran
May 21st, 2006
In the following code p2 is an integer .from the code , tht we r using typedef to define integer pointer as ptr. so the code looks like tis int* p1,p2; whic is equivalent to int *p1,p2;hence p2 is an integer pointer.
though the default scope is integer there is no compulsion that we should return an integer and we know that a void function can't return a value by using return statement.at the same time a void func...
#include<stdlib.h> int main() { char s[]="567.2.2.2"; int a; a=atoi(s); if(a>256) printf("%d is greater",a); else printf("%d is smaller",a); } atoi function which converts string to integer which returns integer 567 in this program
A string constant consists of a sequence of characters enclosed indouble-quote marks.? For example:char *p="hello";constant string is const char *p="hello";
For handling multithreading in c programming the two common libraries that is mainly used are LIBCMT.LIB and MSVCRT.LIB. The compiler must be ensured about the usage of these libraries while implementing multithreading in c programming.
Pointers to functions concept is used in C programming language in various instances. One of the common instance in which programmers use pointers to function concept is for passing pointers to a func...
Function pointers are actually pointers. The address of a function gets pointed to by function pointer.Example of defining a function pointer is as below:int (*exforsys)(int,float)= NULL;
Ans