How can we count the amount of double nbs and that of integer nbs in a specific txt file?! | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

How can we count the amount of double nbs and that of integer nbs in a specific txt file?!

In c++

12th May 2019, 12:04 PM
Manar Ksm
Manar Ksm - avatar
4 Answers
+ 1
Brute force approach isnum(fptr[I])
12th May 2019, 12:08 PM
‎ ‏‏‎Anonymous Guy
+ 1
Yes Steps 1. Open file using file operations 2. Read character until EOF (End Of File) is reached, using any loop 3. Compare every character and check if it's a number or not. 4. If it's a number store it into an array 5. Close file
12th May 2019, 12:16 PM
‎ ‏‏‎Anonymous Guy
+ 1
‎ ‏‏‎Sreejith  okay thanks for your help :)
12th May 2019, 12:18 PM
Manar Ksm
Manar Ksm - avatar
0
‎ ‏‏‎Sreejith  this code found in c++ programming ??
12th May 2019, 12:12 PM
Manar Ksm
Manar Ksm - avatar