About me
- I'm 28 years old
- Love to learn
- Love to make life around better
- Team player
Yekaterinburg, Russia
Code for Codewars kata "Square Every Digit": this function squares every digit of a number and concatenate them. For example, if we run 9119 through the function, 811181 will come out, because 92 is 81 and 12 is 1.
function squareDigits(num){
let num_string = num.toString();
let square = 0;
let new_string = '';
for(let i = 0; i < num_string.length; i++){
console.log(square = Math.pow(parseInt(num_string[i], 10), 2));
new_string = new_string + square;
}
return parseInt(new_string, 10);
No relevant work experience yet. Did a few learning projects (see my GitHub, link below).
B2 (Upper-Intermediate). Practised during my work as a receptionist, also had an individual and group tutoring experience (as a tutor myself).