C++ You will create a header file with implementation that performs the task. Together with the header and implementation, you create a test program whose main function demonstrates that your functions work as they should. A file contains integers. You must write a function that show whether the integers in the file are in order or not. The test program should give output if a file with digits is sorted or not.. Try to come up with a method on your own before looking the algorithm. Input : file contains numeric values Output :The File is sorted Note : This algorithm you can use it: a ← read Value from the file while not End Of File (eof) implements b ← read Value from the file if a> b then return false end if a ← b end while return true (Algorithm decide if a file is sorted)
C++
You will create a header file with implementation that performs the task.
Together with the header and implementation, you create a test
A file contains integers. You must write a function that show whether the integers in the file are in order or not.
The test program should give output if a file with digits is sorted or not..
Try to come up with a method on your own before looking the
Input : file contains numeric values
Output :The File is sorted
Note : This algorithm you can use it:
a ← read Value from the file
while not End Of File (eof) implements
b ← read Value from the file
if a> b then
return false
end if
a ← b
end while
return true
(Algorithm decide if a file is sorted)
Step by step
Solved in 3 steps with 1 images