--:--









Quiz for File operations fscanf

Course: C Language | Subject: Unit 8 | Topic: File Handling



Logo

Q1: What is the primary purpose of fscanf()?

Logo

Q2: Which header file declares fscanf()?

Logo

Q3: What does fscanf(fp, "%d", &num) do?

Logo

Q4: What is the return value of fscanf() on successful reads?

Logo

Q5: Can fscanf() read strings from a file?

Logo

Q6: What happens if fscanf() fails to read?

Logo

Q7: Which of these is a valid fscanf() usage?

Logo

Q8: Can fscanf() read multiple variables in one call?

Logo

Q9: Which format specifier reads a floating point number?

Logo

Q10: Is fscanf() type-safe?

Logo

Q11: What must be done before using fscanf()?

Logo

Q12: Can fscanf() read binary data?

Logo

Q13: Can fscanf() be used to read from stdin?

Logo

Q14: Does fscanf() skip whitespace automatically?

Logo

Q15: What is the correct way to read a single character with fscanf()?

Logo

Q16: Is it necessary to check the return value of fscanf()?

Logo

Q17: Which argument is mandatory for fscanf()?

Logo

Q18: Can fscanf() read input until newline?

Logo

Q19: Does fscanf() modify the file pointer position?

Logo

Q20: Can fscanf() cause buffer overflow?

Are you ready to start test? Set your time limit