ADDED SCRIPT FOR INDEX OF FIRST LINES