How to get the size, the min and the max of unsigned char Data Type in C

1 Answer

0 votes
#include <stdio.h> 
#include <limits.h> 
 
int main(void)
{   
    printf("%d\n", (int)sizeof(unsigned char));
    printf("%d\n", 0); // min
    printf("%d\n", UCHAR_MAX);
     
    return 0;
}
 
    
/*
run:
 
1
0
255
 
*/

 



answered Dec 10, 2016 by avibootz
edited Dec 11, 2016 by avibootz

Related questions

1 answer 223 views
1 answer 248 views
1 answer 182 views
1 answer 201 views
...