Question: Code in Ocaml please, NOT assembly Write a function rightjustify : int -> int => string such that rightjustify w n returns a string representation
Code in Ocaml please, NOT assembly
Write a function rightjustify : int -> int => string such that rightjustify w n returns a string representation of n padded with enough spaces in front so that the string has width W. (If the string representation of n has length greater than w, no padding should be added). So rightjustify 5 123 should evaluate to the string 123" and rightjustify 1 314 should evaluate to the string "314
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
