Website Summary Files Commits Branches @commit @diff @stats
diff options
context:
space:
mode:
Commitb04dd50e931cacf38e7bc275a6ce43834fd827ea (patch)
Author
 Angel Dimitriev <angel_dimitriev@abv.bg>
2022-03-15 20:11:28 +0200
Committer
 GitHub <noreply@github.com>
2022-03-15 20:11:28 +0200
Filesd6634daf0fabf81ea1abfe0f95a4546867ee0749
Object-oriented_programming_FMI-b04dd50e931cacf38e7bc275a6ce43834fd827ea.tar
Object-oriented_programming_FMI-b04dd50e931cacf38e7bc275a6ce43834fd827ea.tar.gz
Object-oriented_programming_FMI-b04dd50e931cacf38e7bc275a6ce43834fd827ea.zip
Parentc52bfa065e309bfe204dd15c46d9176bcf5e1606 (diff)
Update array_of_students_read.cpp
1 files changed, 1 insertions, 14 deletions
-rw-r--r--Sem. 03/array_of_students_read.cpp15
diff --git a/Sem. 03/array_of_students_read.cpp b/Sem. 03/array_of_students_read.cpp
index ab1f425..655b38c 100644
--- a/Sem. 03/array_of_students_read.cpp
+++ b/Sem. 03/array_of_students_read.cpp
@@ -10,19 +10,6 @@ struct Student
int fn;
};
-void initStudent(Student& st, const char* name, int age, int fn)
-{
- strcpy(st.name, name);
- st.age = age;
- st.fn = fn;
-}
-
-void saveToFile(const Student* students, size_t count, ofstream& file)
-{
- file.write((const char*)students, count * sizeof(Student));
-}
-
-
size_t getFileSize(ifstream& f)
{
size_t currentPos = f.tellg();
@@ -53,4 +40,4 @@ int main()
std::cout << "Name: " << arr[i].name << ", age: " << arr[i].age << ", fn: " << arr[i].fn << std::endl;
delete[] arr;
-} \ No newline at end of file
+}