Write a preprocessor command that uses the ## (concatenation operator) operator in macro expansion.


Difficulty level
This exercise is mostly suitable for students
#include <stdio.h>
#define CHOP(x) func ## x 

int func3(int x, int y)
{
    return x + y;
}


int main()
{
     int x =1 , y =2 , z;
     z = CHOP(3)(x, y); // z = func3 (x, y);
     printf("Value = %d \n", z);

     return 0;
}

Back to the list of exercises
Looking for a more challenging exercise, try this one !!
Kruskal Algorithm - Minimal Spanning Tree