I have a text file vidi1.txt. All this file has is a single number. I have written a C program to read this file & display its contents. This does not give results as expected. Please help.
Code:#include<stdio.h> void main() { FILE *f1; int i; clrscr(); f1=fopen("c:\tcc\vidi1.txt","rb"); printf("Contents of file\n"); i=getw(f1); fclose(f1); printf("%d",i); getch(); }