Pre-processor "define" 2 programs.

in programming •  7 years ago 

Program Body

#include < iostream >
#define ABS(str,wolf)((str) =="sabi" | (wolf)=="alpha" ? "You are right" :("wolfi no wolfie"))
using namespace std;

int main(){
cout<<ABS("wolf","alpha");
}

Second Program Body

#include
#define VAMP
using namespace std;

int main (){
#ifdef VAMP
cout<<"defined wolf"<<endl;
#else
cout<<"not defined"<<endl;
#endif
#undef VAMP
#ifndef VAMP
cout<<"woao it is defined"<<endl;
#else
cout<<"AHH??? not defined dud"<<endl;
#endif // VAMP
}

made in

written in C++ language

Complied in Codeblocks

i hope you guys liked it

Authors get paid when people like you upvote their post.
If you enjoyed what you read here, create your account today and start earning FREE STEEM!
Sort Order:  

Thanks for sharing coding in c++ .i learne it.

thank you guys

Your intrest in programming and studying bio... I cant understand... Your grip in programming dual role well