Question: What is the difference between scanf() and sscanf() functions?
- The scanf() function reads data formatted as a string; The sscanf() function reads string input from the screen.
- The scanf() function reads formatted data from the keyboard; The sscanf() function reads formatted input from a string.
- The scanf() function reads string data from the keyboard; The sscanf() function reads string data from a string.
- The scanf() function reads formatted data from a file; The sscanf() function reads input from a selected string
Answer: The correct answer of the above question is Option B:The scanf() function reads formatted data from the keyboard; The sscanf() function reads formatted input from a string.