Q:

Is there any standard way to use boolean? because my code is giving an error

#include<stdio.h>
boolean ch(char x)
{

if(x>=48&&x<=57)
return 1;
else
return 0;

}
main()
{

if(!ch('t'))
printf("it's a character");

}

error:
cha.c:3: error: boolean' does not name a type
cha.c: In functionint main()':
cha.c:15: error: `ch' was not declared in this scope

A:

Yes, the C99 standard has introduced the _Bool type
Update
Apparently <stdbool.h> also includes the prettier bool type in addition to the true and false macros.  Updated code to reflect this.
#include <stdio.h>
#include <stdbool.h>

bool ch(int);

int main(void)
{
    if(!ch('t'))
        printf("it's a character\n");
    return 0;
}

bool ch(int x)
{
    if (x >= 48 && x <= 57)
        return true;
    else
        return false;
}

Click this link to see the compiled code's output

