Arm/decstr2

From ASMBits

arm/decstr1Previous

Write a function that reads an ASCII null-terminated string containing decimal digits, and returns the value of the number. The string may start with '-' to indicate a negative number, and the remaining characters are decimal digits. The number is guaranteed to fit within an signed 32-bit number.

Sample Input

"1234"

Sample Output

r0=1234 (or 0x4d2)

Write your solution here

Upload a source file...