How to get screen height, div height using javascript

Height of screen (based on our display resolution):

Inside document.ready

var height=screen.height;
alert(height);

Height of window: 

var screenheight = $(window).height();
alert(screenheight);

Height of div(class):