answersLogoWhite

0

read, fread, fgetc, fgets, fscanf etc... use the help/manual

User Avatar

Wiki User

∙ 15y ago

What else can I help you with?

Related Questions

How do you open include file in c?

1. You (human) want to read an include file: use a text editor. 2. Your program wants to read a file: use open/fopen.


A program in c to copy text file?

File Operations in C are accomplished by the use of pointers.Pointers are use to point to a particular memory location.File are read and written by using file pointers.The Keyword FILE is used to declare a file pointer.The Complete Program for writing text to a file and saving it and copying it to a new location is given at http://c-madeeasy.blogspot.com/2011/07/program-in-c-to-write-data-to-file-and.html


Can you read a file after created by a program in C plus plus?

Yes. You can either create a file for both reading and writing, or you can re-open a file for reading after creating and writing to it.


Java program that reads a file and display the file on the screen with a line number before each line?

import java.io.*; class Files { public static void main(String a[])throws IOException { int i,line=0,c=0,len; char k; boolean m; File f=new File("info.txt"); FileInputStream f1=new FileInputStream("info.txt"); len=f1.available(); for(i=0;i<=len;i++) { k=(char)f1.read(); c++; System.out.print(k); if(k='/n') { line++; System.out.println(+line); } } System.out.print("number of characters="+c); } }


Is it possible to skip to a new line when reading from a file in c plus plus?

To skip to a new line when reading from a file, assuming you are using a sequentially organized file, the usual case, you need to read and discard characters until you encounter the end-of-line character.


Why program consists more than one object file in c?

why does a program consists of more than one object file in c++


How do you open C when it prompts you to choose the program to open it with with in a list?

edit your autorun.inf file, add the line open=C:\windows\explorer.exe good luck Kevin


How to write a C program to find the header record in a file .please advice?

Just open the file, read-in N bytes and then examine (parse) for known header values or signature.


Write a C program to extract a given word from a file?

program to extract a given word from a file


Write a c program to read and display a text from the file?

Here's the program: /* Program Start */ #include <stdio.h> int main (void) { FILE *handler; // The "*handler" can be named as anything as you desired char arrText[1000]; handler = fopen("Sampletext.txt", "r"); // We opened a file "Sampletext.txt" ready for reading scanf ("%s", &arrText); // Scan the first line of the file printf ("%s", &arrText); // Display the scanned data from file, to the console fclose (handler); return 0; } /* Program End */ If you wish to print the scanned line to text and not to console, use fprintf insted. fprintf can be executed in this form: fprintf (<file name>, "<format specifier> (or text)", <variable>); Also, use "a" in fopen. This will append the current data to the text file.


How can you read a directory in a C program?

no


You want a file handling c program?

yes

Trending Questions
What is the positive of nuclear power plant? What code used in present day computing was developed by IBM corporation? What does duct work mean? What do lasers convert electrical signals into pulses of? Should one provide 12volts for charging two 6volt batteries which are connected in such a way that cathode of one battery is connected to cathode of other and anode is also connected in similar manner? Why programming language is invented? Can a midget or baby through in a toilet? The 6 steps of the design process? You want to ask a javascript question - Is there any method in javascript that will be called when body is completely loaded? What is civil engineering aspects of white cement? When was Principles of Compiler Design created? What do miners wear on their feet? How do you calculate the capacity factor of a centrifuge knowing the density and viscosity of the fluid the density and the diameter of the particles the flow and the diameter if the centrifuge? Who is the founder of science and technology? What are the benefits of bridges? What kind of database stores each record as a line of text and uses commas tabs or other indicators within the line to separate the fields within the record? Can a domestic calorifier be mounted horizontally? Can you connect to database in unix environment using c or c plus plus languages? How do you power a 3 volt DC motor with a 12 volt battery? Why cant you implement centre tapped full wave rectifier without centre tapped transformer?