๐ŸŒ
Fresh2Refresh
fresh2refresh.com โ€บ home โ€บ c programming tutorial โ€บ c โ€“ operators and expressions โ€บ c โ€“ special operators
Special Operators in C | C Operators and Expressions | Fresh2Refresh
September 22, 2020 - Below are some of the special operators that the C programming language offers. In this program, โ€œ&โ€ symbol is used to get the address of the variable and โ€œ*โ€ symbol is used to get the value of the variable that the pointer is pointing to.
๐ŸŒ
Thiyagaraaj
c-lang.thiyagaraaj.com โ€บ tutorials โ€บ c-operators โ€บ special-operators-in-c
Special Operators In C - C Programming
This is called "referencing" operater. ... The dereference operator or indirection operator, noted by asterisk ("*"), is also a unary operator in c languages that uses for pointer variables. It operates on a pointer variable, and returns l-value equivalent to the value at the pointer address.
People also ask

How are file operators in C used?
File operators in C are used to open, close, read, write, and manipulate files using functions like fopen, fclose, fwrite, and fread.
๐ŸŒ
wscubetech.com
wscubetech.com โ€บ resources โ€บ c-programming โ€บ operators
Operators in C Programming (All Types With Examples)
How many types of operators are there in C language?
In C language, there are several types of operators: arithmetic, relational, logical, bitwise, assignment, and special operators.
๐ŸŒ
wscubetech.com
wscubetech.com โ€บ resources โ€บ c-programming โ€บ operators
Operators in C Programming (All Types With Examples)
Can you overload operators in C?
No, C does not support operator overloading, unlike languages such as C++.
๐ŸŒ
wscubetech.com
wscubetech.com โ€บ resources โ€บ c-programming โ€บ operators
Operators in C Programming (All Types With Examples)
๐ŸŒ
GeeksforGeeks
geeksforgeeks.org โ€บ c language โ€บ operators-in-c
Operators in C - GeeksforGeeks
Unary Operators: Operators that work on single operand. Example: Increment( ++ ) , Decrement( -- ) Binary Operators: Operators that work on two operands. Example: Addition ( + ), Subtraction( - ) , Multiplication ( * ) Ternary Operators: Operators ...
Published ย  November 1, 2025
๐ŸŒ
W3Resource
w3resource.com โ€บ c-programming โ€บ c-special-operator.php
C Programming Special Operators: Comma, Sizeof, Pointers, and More
In C programming, aside from the ... for specific tasks. These include: Comma Operator ( , ), Sizeof Operator (sizeof), Pointer Operators (& and *), and Member Selection Operators (....
๐ŸŒ
Medium
medium.com โ€บ @maxnegi333 โ€บ special-operators-are-used-in-the-c-programming-language-to-carry-out-particular-operations-that-56b66db449a9
Special operators are used in the C programming language to carry out particular operations thatโ€ฆ
September 24, 2023 - Special operators are used in the C programming language to carry out particular operations that are incompatible with standard arithmetic or logical operators. These operators stand out because of their distinct functionality and syntax.
๐ŸŒ
WsCube Tech
wscubetech.com โ€บ resources โ€บ c-programming โ€บ operators
Operators in C Programming (All Types With Examples)
August 29, 2025 - Learn about operators in C programming with detailed examples. Explore all types: arithmetic, logical, relational, bitwise, and more for coding efficiency.
๐ŸŒ
Wikitechy
wikitechy.com โ€บ tutorials โ€บ c-programming โ€บ special-operators-in-c-programming
[100% Working Code] - Special Operators in C Programming - C Programming - C Tutorial - Wikitechy
Special Operators in C Programming - In C Programming the special operators are mostly used for memory related functions. & Operator is used to get the address of the variable. The real address or physical address of a variable is the real location of the variable in memory and is usually only ...
Find elsewhere
๐ŸŒ
EDUCBA
educba.com โ€บ home โ€บ software development โ€บ software development tutorials โ€บ c programming tutorial โ€บ c operators
C Operators: Definition, Types, Precedence and Examples
September 12, 2023 - In these 3, the execution of the first operand happens first. Then the execution of the second operand, if it is non-zero, or a third operand executes to provide the necessary Output. Besides the operators discussed above, C programming language supports a few other special operators like sizeof and โ€œ?:โ€.
Call ย  +917738666252
Address ย  Unit no. 202, Jay Antariksh Bldg, Makwana Road, Marol, Andheri (East),, 400059, Mumbai
๐ŸŒ
BtechSmartClass
btechsmartclass.com โ€บ c_programming โ€บ C-Operators.html
C Tutorials - Operators in C Programming Language
An operator is a symbol used to perform arithmetic and logical operations in a program. That means an operator is a special symbol that tells the compiler to perform mathematical or logical operations.
๐ŸŒ
W3Schools
w3schools.com โ€บ c โ€บ c_operators.php
C Operators
C Examples C Real-Life Examples C Exercises C Quiz C Code Challenges C Compiler C Syllabus C Study Plan C Interview Q&A C Certificate ... Operators are used to perform operations on variables and values.
๐ŸŒ
Programiz
programiz.com โ€บ c-programming โ€บ c-operators
Operators in C
April 27, 2022 - An operator is a symbol that operates on a value or a variable. For example: + is an operator to perform addition. In this tutorial, you will learn about different C operators such as arithmetic, increment, assignment, relational, logical, etc. with the help of examples.
๐ŸŒ
ScholarHat
scholarhat.com โ€บ home
Operators in C: Types of Operators
To test your theoretical concepts, consider our C Programming Course. Operators are special symbols used to perform various mathematical and logical operations on variables and symbols known as operands.
Published ย  July 31, 2025
๐ŸŒ
TutorialsPoint
tutorialspoint.com โ€บ home โ€บ cprogramming โ€บ c operators
C Operators
June 10, 2012 - Depending on how many operands are required to perform the operation, operands are called as unary, binary or ternary operators. They need one, two or three operands respectively. Unary operators โˆ’ ++ (increment), -- (decrement), !
๐ŸŒ
Slideshare
slideshare.net โ€บ home โ€บ education โ€บ conditional and special operators
Conditional and special operators | PPTX
It uses the symbols '?' and ':' and has the syntax "variable = Expression1 ? Expression2 : Expression3". Some other special operators in C include sizeof() which returns the size of a variable, & which returns the address of a variable, and * which is used as a pointer to a variable.
๐ŸŒ
Slideshare
slideshare.net โ€บ home โ€บ business โ€บ operators in c programming
Operators in C Programming | PPT
BITWISE OPERATORS ๏ฝ Theseoperators ... ... SPECIAL OPERATORS 'C' supportssome special operators such as comma operator, sizeof operator and pointer operators....
Top answer
1 of 5
10

"Now, is there any way to define it instead that with an operator, with some function?"

No, !+ doesn't form a valid (normal) identifier for a preprocessor macro. The characters are reserved for language intrinsic operators.

The set of characters you can use for macro definitions is [_A-Za-z][_A-Za-z0-9]*regex syntax1.

As from the c++ standards definitionsdraft section

16 Preprocessing directives

...
control-line:
...
# define identifier replacement-list new-line
# define identifier lparen identifier-listopt) replacement-list new-line
# define identifier lparen ... ) replacement-list new-line
# define identifier lparen identifier-list, ... ) replacement-list new-line


UPDATE:
I've been experimenting with this a bit, since this actually is an interesting question, and if not #define'd macros, we can use overloading intrinsic operator functions for classes in c++.

I have found there actually are possible (but may be weird and unexpectedly behaving) options, to overload combinations of intrinsic operators by chaining them and keep state. The closest thing you can get for your newly introduced operator could be:

class Foo {
    enum OpState { None , PlusState , NotState };   
public:
   Foo& operator+() {
       cout << "operator+()" << endl;
       opState = PlusState;
       return *this;
   }
   Foo& operator!() {
       cout << "operator!()" << endl;
       switch(opState) {
       case PlusState:
           operatorexclamativeplus();
           break;       
       default:
           opState = NotState;
           break;       
       }
       return *this;
   }    
private:
    Foo& operatorexclamativeplus() {
       cout << "operatorexclamativeplus()" << endl;
       opState = None;
       return *this;
    }
    Foo& operatorexclamativeplus(const Foo& rhs) {
       cout << "operatorexclamativeplus(const Foo& rhs)" << endl;
       opState = None;
       return *this;
    }   
    OpState opState;
};

int main() {
    Foo x;
    Foo z = !+x;
    return 0;
}

Output

operator+()
operator!()
operatorexclamativeplus()

See live sample.


Though, because of operator precedence rules, this would work only for unary operators (! has higher precedence than binary +), the form you want to have doesn't seem to be actually achievable:

class Foo {
    // ...
public:
    // Provide an additional binary 'operator+()'
    friend Foo& operator+(Foo& lhs, const Foo& rhs) {
        cout << "operator+(Foo& lhs, const Foo& rhs)" << endl;
        if(lhs.opState == NotState) {
            return lhs.operatorexclamativeplus(rhs);
        }
        return lhs;
    }
    // ...
};

int main() {
    Foo x;
    Foo y;
    Foo z = y !+ x;
    return 0;
}

See this miserably fail.


CONCLUSION:

  1. Some overloaded combinations of intrinsic operators might be syntactically possible, regarding their precedence definitions, and maintaining state of lvalues.
  2. It's probably not a very good idea, to try to overload intrinsic operator behavior, introducing completely new semantics.

______________________________________________________________________________________

1) Regarding leading underscores (_,__) for identifiers please read the standards sections mentioned in this answer, these are syntactically valid though.

2 of 5
1

Technically, C++ does not let you define new operators. However, you can get any behavior you want out of existing operators, including the appearance of having a new operator.
(Not saying it's a good idea, just answering the question "Is it possible?")

You can not ever write a !+ b, becuase ! is not a binary operator.
But you can write a +! b because + is binary and ! is unary.
And you can redefine those operators so that a +! b returns what you want.

The trick is that you define the unary operator to return a helper object, and then define the binary operator to act upon that helper object.

As an example, here is code that will create the appearance of a +! operator. This new +! operator returns ten times the left hand side plus the right hand side. So... 1 +! 2 would yield 12.

class MyClass
{
public:
    int value;
};

class MyClassHelper
{
public:
    int value;
};

// define a unary ! operator that takes a right hand MyClass object
const MyClassHelper operator!(const MyClass right)
{
    // this operator just copies the value into a MyClassHelper object
    MyClassHelper answer;
    answer.value = right.value;
    return answer;
}

// define a binary + operator that takes a left hand MyClass object and a right hand MyClassHelper object
const MyClass operator+(const MyClass left, const MyClassHelper right)
{
    // this operator should return the value you want the +! operator to return
    MyClass answer;
    answer.value = left.value * 10 + right.value;
    return answer;
}

int main()
{
    // initialize a and b
    MyClass a, b;
    a.value = 1;
    b.value = 2;

    // this line will now compile with the +! operator
    MyClass c;
    c = a +! b;
    cout << "c = " << c.value << endl;

    return 0;
}
๐ŸŒ
Aimtocode
aimtocode.com โ€บ special-operators-in-c.php
Special Operators In C Programming with Examples-Aimtocode
For example, to perform an addition operation on operands a and b, the addition(+) operator is combined with the operands a and b forming an expression. In C programming the special operators are mostly used for memory related functions.
๐ŸŒ
Studytonight
studytonight.com โ€บ c โ€บ operators-in-c.php
operators in C in
Operators can be used to perform ... the C operators on data. The C language supports the following type of operators: ... Special operators like sizeof, &, *, ....