New Member FAQ
|
Forums
|
Earn Revenue
|
Distance Education
|
Help Topics
|
Admissions 2013
Awards & Gifts
Login
Register
Articles
Practice Tests
Ask Experts
Question Papers
Jobs
Universities
Colleges
Courses
Schools
Gift Shop
|
Bookmarks
|
Reviews
|
Learn English
|
Social Hub
|
Training
|
New Posts
|
My India
|
Members
|
Polls
|
Active Members
Today
R Pramod
(96)
Venkiteswaran.
(46)
Brijendra Kumar...
(45)
Last 7 Days
R Pramod
(892)
K Mohan
(682)
yash
(640)
more...
Join our online
Google+ community
for Bloggers, Content Writers and Webmasters
Forums
»
Education
»
General
»
Solve it easy c question
Posted Date:
05 Jun 2009
Posted By::
Malathi
Member Level:
Silver
Member Rank:
3954
Points
: 1
Responses:
4
#define clrscr() 100
main()
{
clrscr();
printf("%d\n",clrscr());
}
Tweet
Responses
#88910 Author:
Deepakkumar Devarajan
Member Level:
Gold
Member Rank:
0
Date: 05/Jun/2009 Rating:
Points
: 1
I guess zero or one might the output , I am not good in C or C++, please let me know the answer
Regards,
Deepakkumar D
Join My community :
#89418 Author:
Malathi
Member Level:
Silver
Member Rank:
3954
Date: 07/Jun/2009 Rating:
Points
: 3
Explanation:
Preprocessor executes as a seperate pass before the execution of the compiler. So textual replacement of clrscr() to 100 occurs.The input program to compiler looks like this :
main()
{
100;
printf("%d\n",100);
}
Note:
Line 1: 100; is an executable statement but with no action. So it doesn't give any problem
Answer: 100
#89581 Author:
Deepakkumar Devarajan
Member Level:
Gold
Member Rank:
0
Date: 08/Jun/2009 Rating:
Points
: 0
Malathi,
I have not seen the preprocessor statement :-) so i thought clrscr() is a predefined function. Well , keep posting questions like this, it'll make us to use our Brain.
Regards,
Deepakkumar D
Join My community :
#90346 Author:
Akilanda Nageswari
Member Level:
Bronze
Member Rank:
5026
Date: 13/Jun/2009 Rating:
Points
: 0
100 shown in the output screen
Post Reply
This thread is locked for new responses. Please post your comments and questions as a
separate thread
.
If required, refer to the URL of this page in your
new post
.
Tweet
Next :
C quiz
Previous :
netconnect broadband+ - tariff plans
Return to Discussion Forum
Post New Message
Category:
Related Messages
c programmming language
computer technology
Problem solving using C language
who to study in last time.............
Need Career Shift
Subscribe to Email
Get Jobs by Email
Forum posts by Email
Articles by Email
Online Members
Dhairya Khant
Komal Sood
Jebaprincy
Saroja
rahul
sageer
Sudarmani
vamshi
Nityananda Hazarika
Ramprasad
indurani
More...
About Us
Contact Us
Copyright
Privacy Policy
Terms Of Use
AdSense Revenue Sharing sites
Advertise
Talk to
Tony John
ISC Technologies, Kochi - India. Copyright © All Rights Reserved.