C # program to find rank of an element in a stream .
using System ; class GFG { public class Node { public int data ; public Node left , right ; public int leftSize ; } static Node newNode ( int data ) { Node temp = new Node ( ) ; temp . data = data ; temp . left = null ; temp . right = null ; temp . leftSize = 0 ; return temp ; }