Finding size of Union variable || Unions || C programming
In this, we are going to print Size of Variable using Unions with help of C Programming Language.

 

#include <stdio.h>
union hfc
{
    //defining a union
    char name[32];
    float salary;
    int workerNo;
} Job;
int main()
{
    printf("size of union = %d bytes", sizeof(Job));
    return 0;
}

//.........Coded by ARADHANA MISHRA

#ENJOY CODING


Post a Comment

FOR ANY DOUBTS AND ERRORS FEEL FREE TO ASK. YOUR DOUBTS WILL BE ADDRESSED ASAP

Previous Post Next Post