diff options
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.cpp | 6 |
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') {} |
