Introduction to File Processing :-
File एक named location है, जिसका उपयोग computer में data और information को स्थायी रूप से store करने के लिए किया जाता है। File में text, numbers, images, audio, video या अन्य प्रकार का data रखा जा सकता है।
जब हम किसी program में variable का उपयोग करके data store करते हैं, तो सामान्यतः वह data program के समाप्त होने पर उपलब्ध नहीं रहता। लेकिन file में store किया गया data program बंद होने के बाद भी सुरक्षित रहता है और आवश्यकता पड़ने पर दोबारा उपयोग किया जा सकता है।
English Definition
A file is a named collection of data stored on a storage device for permanent use. It can contain text, numbers, images, audio, video, or other types of information.
Data stored in variables is generally temporary, whereas data stored in a file remains available even after the program terminates.
Example (उदाहरण)
मान लीजिए, हमें किसी विद्यार्थी का नाम और अंक store करने हैं।
इस उदाहरण में name और marks variables में data store है। Program समाप्त होने के बाद यह data variables के रूप में उपलब्ध नहीं रहेगा।
यदि हमें इस data को भविष्य में भी उपयोग करना है, तो इसे file में store कर सकते हैं।
File का उपयोग कहाँ होता है?
विद्यार्थी के नाम और अंक store करने में।
किसी application का record रखने में।
Website के data को save करने में।
Log files में program की activities record करने में।
Text documents, images और videos को store करने में।