kotlin-coding-challenges

Reverse Int

Instructions

Given an integer n, return an integer that is the reverse ordering of digits.

Challenge Solution

Examples

reverseInt(15) // 51

reverseInt(981) // 189

reverseInt(500) // 5

reverseInt(-15) // -51

reverseInt(-90) // -9