Hackerrank – Alternating Characters

Problem Statement A description of the problem can be found on Hackerrank. Solution Iterate through all string characters. If actual character i is different then character i-1 then use character i for next comparison. If they are not equal increment a deletion counter. Print the value of the counter. I created solution in: Java JavaScript […]

Hackerrank – Alien Username

Problem Statement A description of the problem can be found on Hackerrank. Solution Regular Expression that validates input username: ^[_\.]\d+[a-zA-Z]*_?$ I created solution in: Java JavaScript Scala Ruby All solutions are also available on my GitHub. Java

JavaScript

Scala

Ruby