What is meant by opening a data file, Computer Engineering

Assignment Help:

What is meant by opening a data file

A data file is a file that can be read from or written to. Data files are particularly useful when large amounts of data are involved. Each line of a data file is called a record. The following is the first few records of the file ospots.dat (a file containing the total number of sunspots observed in a year during the years 1850-1975):

1850 66.6

1851 64.5

1852 54.1

1853 39.0

1854 20.6

To read from or write to a data file during the execution of a program, the file must first be opened with the function  "fopen". This function takes two arguments - the first one is the path to your file, including the filename. So if your file sits in the same directory as your C source file, you can simply enter the filename in here .   The second argument is another char *, and determines how the file is opened by your program. Finally, fopen returns a FILE pointer if the file was opened successfully, else it returns NULL.

 

 


Related Discussions:- What is meant by opening a data file

What are the uses of interactive reporting, What are the uses of interactiv...

What are the uses of interactive reporting? The user can actively control data retrieval and show during the session.  Instead of an extensive and detailed list, you make a ba

How society is affected thorugh internet, How society is affected thorugh I...

How society is affected thorugh Internet Buying goods and services (for example banking) over the internet has both negative and positive aspects on society. These can be expl

What are the modes in which any update tasks work, What are the modes in wh...

What are the modes in which any update tasks work? Synchronous and Asynchronous.

Device controllers, All components of computer communicate with processor b...

All components of computer communicate with processor by the system bus. Which means I/O devices required to be attached to system bus. But I/O devices aren't connected directly to

How the information can be stored, In a RAM, information can be stored ? A...

In a RAM, information can be stored ? Ans. RAM is used by the user, number of times.

Explain about param super computer, Q. Explain about PARAM Super computer? ...

Q. Explain about PARAM Super computer? PARAM is a high-performance, industry standard and scalable computer. It has developed from concepts of distributes scalable computers ma

Explain what the difference between the two readings, The following sentenc...

The following sentences have a (potential) scope ambiguity. Give two translations into predicate logic for each sentence (one formula for each reading), and explain in words what t

Explain how sap gui handles output screen for the user, Explain how SAP GUI...

Explain how SAP GUI handles output screen for the user. The SAP front-end s/w can either run on the similar computer or on dissimilar computers given for that purpose.  User t

Explain bit-o-ring technique, Explain bit-O-Ring technique. The micro p...

Explain bit-O-Ring technique. The micro program represents that branches are not always made to a one branch address. This is a direct consequence of combining easy micro routi

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd