Skip to content

Instantly share code, notes, and snippets.

View umairqazi523's full-sized avatar
🎯
Focusing

Umair Qazi umairqazi523

🎯
Focusing
View GitHub Profile
let int = -543;
console.log(reverseInt(int));
function reverseInt(integer) {
const reversed = integer.toString().split('').reverse().join('');
return Math.sign(integer) * parseInt(reversed);
}
class TwoSum {
constructor(_inputArray, _targetValue) {
this.inputArray = _inputArray;
this.targetValue = _targetValue
this.outputArray = []
}
get() {
let i, j;