Problem 53750. Easy Sequences 63: Base-63 Arithmetic Functions
In this exercise we are required to implement 7 basic 'unsigned integer' arithmetic functions in base-63:
- to63(x) - converts an integer from base-10 to base-63.
- to10(x) - converts an integer from base-63 to base-10.
- add(x,y) - adds two base-63 integers.
- sub(x,y) - subtracts two base-63 integers.
- mul(x,y) - multiplies two base-63 integers.
- div(x,y) - performs integer division between two base-63 integers.
- mod(x,y) - returns the remainder of division between two base-63 integers.
NOTES:
- All outputs shall be char-string format.
- Except for the function 'to63' (which may input numbers), all inputs shall be in char-string format.
- Use the numerals '0' to '9' for digits 0 to 9, capital letters 'A' to 'Z' for digits 10 to 35, lower case letters 'a' to 'z' for digits 36 to 61 and the symbol '_' (underscore) for digit 62.
Solution Stats
Problem Comments
-
1 Comment
GeeTwo
on 28 Aug 2023
As far as I can tell, the template solution is useless to even frame the answer. After I figured out how to frame the solution, I found this which might help (MATLAB Staff solution, not Xiangrui Xi's solution).
https://www.mathworks.com/matlabcentral/answers/100539-how-can-i-access-subfunctions-from-outside-the-main-function-in-matlab
Solution Comments
Show commentsProblem Recent Solvers3
Suggested Problems
-
Select every other element of a vector
33014 Solvers
-
What is the distance from point P(x,y) to the line Ax + By + C = 0?
372 Solvers
-
716 Solvers
-
172 Solvers
-
Return fibonacci sequence do not use loop and condition version 2
54 Solvers
More from this Author116
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!