Count the number of selected lines In visual mode, press g-C-g Source: https://stackoverflow.com/a/7262572/919641