Become a member
Sign in
Hary Krishnan
Hary Krishnan

Hary Krishnan

https://www.linkedin.com/in/harykrishnan/

29 Following
14 Followers
  • Profile
  • Claps

Latest

Hary Krishnan
Hary Krishnan
Aug 1, 2018 · 3 min read

String to Integer (atoi)

1

Hary Krishnan
Hary Krishnan
Jul 29, 2018 · 1 min read

Reverse String

Reverse String - LeetCode

Write a function that takes a string as input and returns the string reversed. Example: Given s = "hello", return…

leetcode.com

Hary Krishnan
Hary Krishnan
Jul 29, 2018 · 2 min read

Roman To Integer

Example:

Roman numerals are represented by seven different symbols: I, V, X, L, C, D and M.

For example, two is written as II in Roman numeral, just two one’s added together. Twelve is written as, XII, which is simply X + II. The number…

Hary Krishnan
Hary Krishnan
Jul 16, 2018 · 2 min read

Ransom Note

Example:

Given an arbitrary ransom note string and another string containing letters from all the magazines, write a function that will return true if the ransom note can be constructed from the magazines ; otherwise, it will return false.

Hary Krishnan
Hary Krishnan
Jul 16, 2018 · 3 min read

Array Nesting

Example:

A zero-indexed array A of length N contains all integers from 0 to N-1. Find and return the longest length of set S, where S[i] = {A[i], A[A[i]], A[A[A[i]]], … } subjected to the rule below.