Apr 262016
 

Write a Simple function that accepts a character and return true if it is a digit else return false:

Solution:

bool isDigit(char ch)
{
	return (ch >='0' && ch<='9');
}

The above function is self-explanatory.

 Leave a Reply

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

(required)

(required)