Summary Files Commits Branches @commit @diff @stats
path: root / Year 1 / Object-oriented Programming / Solutions Sem. 03 / ex4 / Bytex.cpp
diff options
context:
space:
mode:
Commita6fb61db10a93801065d34d19fb6d7166511e58d (patch)
Author
 Syndamia <kamen.d.mladenov@protonmail.com>
2022-03-31 09:37:42 +0300
Committer
 Syndamia <kamen.d.mladenov@protonmail.com>
2022-03-31 09:37:42 +0300
Filesec3db1d6147713c184c9ba23fd9dd866c599edcc /Year 1/Object-oriented Programming/Solutions Sem. 03/ex4/Bytex.cpp
uni-projects-a6fb61db10a93801065d34d19fb6d7166511e58d.tar
uni-projects-a6fb61db10a93801065d34d19fb6d7166511e58d.tar.gz
uni-projects-a6fb61db10a93801065d34d19fb6d7166511e58d.zip
Parent4a530b9ae9f50ce0e117931933db3a11285f29af (diff)
Made naming and slight formatting adjustments
1 files changed, 5 insertions, 1 deletions
-rw-r--r--Year 1/Object-oriented Programming/Solutions Sem. 03/ex4/Bytex.cpp6
diff --git a/Year 1/Object-oriented Programming/Solutions Sem. 03/ex4/Bytex.cpp b/Year 1/Object-oriented Programming/Solutions Sem. 03/ex4/Bytex.cpp
index 42a03c6..bc2bee6 100644
--- a/Year 1/Object-oriented Programming/Solutions Sem. 03/ex4/Bytex.cpp
+++ b/Year 1/Object-oriented Programming/Solutions Sem. 03/ex4/Bytex.cpp
@@ -1,6 +1,8 @@
#include "Bytex.h"
-char Bytex::digitToHexChar(unsigned int digit) {
+/* Private functions */
+
+char Bytex::digitToHexChar(int digit) {
if (digit < 10)
return '0' + digit;
return 'A' + digit - 10;
@@ -22,6 +24,8 @@ void Bytex::hexValToByte() {
byteVal = hexCharToNum(hexVal[0]) * 16 + hexCharToNum(hexVal[1]);
}
+/* Public functions */
+
Bytex::Bytex() : Bytex('\0')
{}