Check if given binary tree is height balanced or not

Given a binary tree, write an efficient algorithm to check if tree is height balanced or not. In a height balanced tree, the absolute difference between height of left subtree and right subtree for every node is 0 or 1.  

Implement substr function in C

Write an efficient function to implement substr function in C. substr() function returns the substring of given string between two given indexes.

Implement strcmp() function in C

Write an efficient function to implement strcmp function in C. Standard strcmp() function compares the two strings and returns an integer indicating the relationship between the two strings.