added delete routine
print index