modern C does suppport bool u need to include *#include<stdbool.h> * header it will work fine as in C++
On Sat, Oct 27, 2012 at 3:21 AM, rahul sharma <[email protected]>wrote: > There is question asked like > O/p of following in C(32 bit OS) > #include <iostream> > #include<stdio.h> > using namespace std; > > > bool IsEqual(char * a) > { > printf("abc"); > return true; > } > > int main() > { > char str[30]; > printf("%d",sizeof(sizeof(IsEqual(str)))); > getchar(); > return 0; > } > I run with .cpp....i know o/p and all in c++...but c doesn't support > bool.....so what should i write in answer as it is asked in written..so wat > should be writen > > 4 i.e the answer in c++ or should i write that c doesn't support bool > > plez comment > > -- > You received this message because you are subscribed to the Google Groups > "Algorithm Geeks" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group at > http://groups.google.com/group/algogeeks?hl=en. > -- *RAHUL KUMAR DUBEY* *BTech-3rd year * *Computer Science &Engineering * *Motilal Nehru National Institute Of Technology* *Allahabad[211004],UP.* -- You received this message because you are subscribed to the Google Groups "Algorithm Geeks" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en.
