c programming

17 flashcardsby Haseeb1968
Study these flashcardsFree · spaced repetition · iPhone, Android, Mac & web

All cards

1
which library is used for file handling operations
stdio.h
2
use of fopen() and what does it return
it is used to open a file and it returns a pointer to the file
3
which function is used to close a file
fclose()
4
which function is ised to read from a file
fread()
5
use of fseek()
it is used to set the file position to a specified position.
6
use of feof()
It is used to check whether the end of the file is reached or not.
7
use of ftell()
It is used to get the current file position.
8
use of ferror()
It is used to check whether an error occurred during file operation or not.
9
use of remove()
It is used to delete a file.
10
use of rename()
It is used to rename a file.
11
what does the modes do in file
determines where the file is positioned when opeaned and what functions are allowed
e.g after you close a file you can reopean the file in different mode depending upon what you are doing e.g reading , writing or doing both simaltaneously in a file
12
what does this mode does in files "r":
Opens a file for reading. The file must exist.
13
what does this mode does in files "w"
Creates a file for writing. If the file already exists, it is truncated to zero length.
14
what does this mode does in files"a"
Appends to a file. Writing operations are always performed at the end of the file, regardless of the current file position.
15
what does this mode does in files "r+"
Opens a file for both reading and writing. The file must exist.
16
what does this mode does in files w+
Creates a file for both reading and writing. If the file already exists, it is truncated to zero length.
17
what does this mode does in files a+"
Opens a file for both reading and appending. Writing operations are always performed at the end of the file, regardless of the current file position.
Study all 17 cards for free

More Computer science flashcards

Sorting Algorithms22 cardsComputer science · EnglishMariaWhat is a Computer/Computer System? (Exam Mode Edition)13 cardsComputer science · EnglishM05SYcomputer science 34 cards · 1 addedComputer science · EnglishKayinITEC 110: Information Technology and Cybersecurity147 cardsComputer science · EnglishmackNetworking: Topologies and NOS96 cardsComputer science · EnglishJayHDL and Assembly Language Midterm Exam74 cardsComputer science · EnglishDiandreiCCNA 1 Mod 11 IPv4 Addressing61 cardsComputer science · EnglishManethelGdS: Lektion 3 - Requirements Engineering51 cardsComputer science · GermanSam1303ITEC110 part 142 cardsComputer science · EnglishsabAtmopy Unit 1 36 cardsComputer science · EnglishMiriComputer Hardware Components30 cardsComputer science · EnglishAyaanMicro 3-2 Yu24 cardsComputer science · EnglishDiandrei

All Computer science decks

Study these decks in the app

Free on iPhone, Android, Mac and the web. Add any deck to your account in one tap.

Download on the App StoreGet it on Google Play
Study all 17 cards for free