Skip to content
Courses
DSA to Development
Get IBM Certification
Newly Launched!
Master Django Framework
Become AWS Certified
For Working Professionals
Interview 101: DSA & System Design
Data Science Training Program
JAVA Backend Development (Live)
DevOps Engineering (LIVE)
Data Structures & Algorithms in Python
For Students
Placement Preparation Course
Data Science (Live)
Data Structure & Algorithm-Self Paced (C++/JAVA)
Master Competitive Programming (Live)
Full Stack Development with React & Node JS (Live)
Full Stack Development
Data Science Program
All Courses
Tutorials
Data Structures & Algorithms
ML & Data Science
Interview Corner
Programming Languages
Web Development
CS Subjects
DevOps And Linux
School Learning
Practice
Build your AI Agent
GfG 160
Problem of the Day
Practice Coding Problems
GfG SDE Sheet
Contests
Accenture Hackathon (Ending Soon!)
GfG Weekly [Rated Contest]
Job-A-Thon Hiring Challenge
All Contests and Events
DSA
Practice Problems
Python
C
C++
Java
Courses
Machine Learning
DevOps
Web Development
System Design
Aptitude
Projects
Sign In
▲
Similar Topics
C++
4k+ articles
C++ Programs
2.5k+ articles
C Language
1.8k+ articles
C Programs
800+ articles
CPP-Functions
600+ articles
C Quiz
280+ articles
CPP-Basics
90+ articles
C Basics
76 articles
C-Macro & Preprocessor
33 articles
cpp-macros
11 articles
Macro & Preprocessor
21 posts
Popular Articles
Recent Articles
#define vs #undef in C language
Last Updated: 22 June 2023
In this article, we will discuss the difference between #define and #undef pre-processor in C language.What are Pre-Processor Directives?Pre
...read more
C Language
C-Macro & Preprocessor
Macro & Preprocessor
C Programs
Types of pragma directives in C
Last Updated: 04 April 2021
Pragma Directives: The pragma directive is used to control the actions of the compiler in a particular portion of a program without affectin
...read more
C Macro
C Language
C-Macro & Preprocessor
Macro & Preprocessor
C Programs
include guards in C++
Last Updated: 17 August 2023
While programming in C++ we often use a class multiple times, and hence it requires to create a header file and just include it in the main
...read more
CPP-Basics
C++
Macro & Preprocessor
C++ Programs
Similar Topics
C++
4k+ articles
C++ Programs
2.5k+ articles
C Language
1.8k+ articles
C Programs
800+ articles
CPP-Functions
600+ articles
C Quiz
280+ articles
CPP-Basics
90+ articles
C Basics
76+ articles
C-Macro & Preprocessor
33+ articles
cpp-macros
11+ articles
#pragma Directive in C
Last Updated: 09 January 2024
In C, the #pragma directive is a special purpose directive that is used to turn on or off some features. #pragma also allows us to provide s
...read more
C Language
C-Macro & Preprocessor
Macro & Preprocessor
errno constant in C++
Last Updated: 14 August 2021
errno is a preprocessor macro used for error indication.The value of errno is set to zero at program startup, and any function of the standa
...read more
CPP-Functions
cpp-macros
C++
Macro & Preprocessor
C Preprocessor Directives
Last Updated: 02 April 2025
In C programming, the preprocessor is a program that process the source code before the actual compilation begins. It uses preprocessor dire
...read more
C Basics
cpp-macros
C Language
C++
C-Macro & Preprocessor
Macro & Preprocessor
C | Macro & Preprocessor | Question 12
Last Updated: 28 June 2021
Predict the output of following program?[sourcecode language="C"]#include stdio.h#define MAX 1000int main(){ int MAX = 100; printf(%d ,
...read more
C Language
C Quiz
C-Macro & Preprocessor
Macro & Preprocessor
C | Macro & Preprocessor | Question 11
Last Updated: 28 June 2021
What is the use of \"#pragma once\"?(A)Used in a header file to avoid its inclusion more than once.(B)Used to avoid multiple declarations of
...read more
C Language
C Quiz
C-Macro & Preprocessor
Macro & Preprocessor
C | Macro & Preprocessor | Question 10
Last Updated: 12 February 2013
Which file is generated after pre-processing of a C program?(A).p(B).i(C).o(D).m Answer: (B)Explanation:After the pre-processing of a C pro
...read more
C Language
C Quiz
C-Macro & Preprocessor
Macro & Preprocessor
C | Macro & Preprocessor | Question 7
Last Updated: 06 February 2013
Output?[sourcecode language="C"]# include stdio.h# define scanf %s Geeks Quiz int main(){ printf(scanf, scanf); return 0;}[/sourcecode]
...read more
C Language
C Quiz
C-Macro & Preprocessor
Macro & Preprocessor
C | Macro & Preprocessor | Question 6
Last Updated: 28 June 2021
[sourcecode language="C"]#include stdio.h#define square(x) x*xint main(){ int x; x = 36/square(6); printf(%d, x); return 0;}[/sourcecode
...read more
C Language
C Quiz
C-Macro & Preprocessor
Macro & Preprocessor
C | Macro & Preprocessor | Question 5
Last Updated: 05 February 2013
[sourcecode language="C"]#include stdio.h#define ISEQUAL(X, Y) X == Yint main(){ #if ISEQUAL(X, 0) printf(Geeks); #else
...read more
C Language
C Quiz
C-Macro & Preprocessor
Macro & Preprocessor
C | Macro & Preprocessor | Question 14
Last Updated: 28 June 2021
What is the output of following program?[tabby title="C"][sourcecode language="c"]#include #define macro(n, a, i, m) m##a##i##n#define MAIN
...read more
C Language
C Quiz
C-Macro & Preprocessor
Macro & Preprocessor
C | Macro & Preprocessor | Question 2
Last Updated: 02 February 2013
[tabby title="C"][sourcecode language="c"]#include #if X == 3 #define Y 3#else #define Y 5#endifint main(){ printf(\"%d\", Y); r
...read more
C Language
C Quiz
C-Macro & Preprocessor
Macro & Preprocessor
C | Macro & Preprocessor | Question 1
Last Updated: 12 January 2013
[sourcecode language="C"]#include stdio.h#define PRINT(i, limit) do \ { \ if (i++ limit)
...read more
C Language
C Quiz
C-Macro & Preprocessor
Macro & Preprocessor
1
2
>>
Last
1
2
>>
Last
1
2
>>
Last
We use cookies to ensure you have the best browsing experience on our website. By using our site, you acknowledge that you have read and understood our
Cookie Policy
&
Privacy Policy
Got It !