Declare And Initialize A Decimal Constant And Output It's Octal And Hexadecimal Value To User




Declare And Initialize A Decimal Constant And Output It's Octal And Hexadecimal Value To User

In this example, you will learn to Declare And Initialize A Decimal Constant And Output It's Octal And Hexadecimal Value To User in C language.

Code For  "Declare And Initialize A Decimal Constant And Output It's Octal And Hexadecimal Value To User".

/* Author --> HARSH PATEL */

#include<stdio.h>
int main ()
{
    int num1=10;

    printf("Octal Value of %d is %o",num1);
    printf("\n Hexadecimal Value of %d is %x",num1);

    return 0;

}
Output

Octal Value of 10 is 25556035050
 Hexadecimal Value of 10 is 

  • Now Program End Without Any Error.

🖥️ Learn Programming Languages Free In Our Website Coding With Harsh 
👨‍🎓 5000+ Happy Visitor 👩‍🎓
🌐 Free Programing Examples In WebsitCoding With Harsh 

  • If Any Query Regarding Programs, Website Or More Details Email Us On Contact@CodingWithHarsh.gq

Popular posts from this blog

C Program To Print Hello World

Declare And Initialize Two Character Constants And Output It To User

C Program To Calculate Profit Or Loss