No, C's scanf() function does not have the ability to verify if integers are within a specific range. It is the responsibility of the program to validate input and ensure that the integer falls within a specific range. This can be done using conditional statements or loops.
Please start posting anonymously - your entry will be published after you log in or create a new account. This space is reserved only for answers. If you would like to engage in a discussion, please instead post a comment under the question or an answer that you would like to discuss
Asked: 2021-05-21 11:00:00 +0000
Seen: 11 times
Last updated: Mar 09 '23