Started translation from PHP into Hack
Further translated PHP code into hack!