// sample cursor
Cursor c = new CursorImpl("to");
c.isValid() // true, positioned at first instance of "to"
c.get() // DP(0,0), first "to"
c.seek (new DP(0, 2)) // false, third position is "or"
c.get() // DP(0, 4) // after previous seek, moved to next occurrence of "to"
c.advance()
c.get() // DP(1,0)
c.advance() 
c.isValid() // false, no more "to" terms
*/


public void printDocIds(String term) {
 // implement
	Cursor c = new CursorImpl(term);
	
	if(!c.isValid()) {
		System.out.println("Not found");
		return;
	}
	
	while(c.isValid()) {
		int docId = c.get().docId;
		System.out.println(docId);
		
		c.seek(new DP(docId+1,0));		
	}
	
	
 
 
 
}