public static BTNode<E> treeCopy(BTNode<E> source)
{
if(source == null)
return null;
else
{
BTNode left = BTNode.treeCopy(source.left);
BTNode right = BTNode.treeCopy(source.right);
return new BTNode(source.data, left, right);
}
}
My questions is why can't I use the generic Type E in a static context? I tried search for several answers couldn't find any that make snese.