import java.nio.*;
import java.nio.ShortBuffer;

public class ShortBuffHasCode{
	public static void main(String[] args) {
		ShortBuffer shortBuf = ShortBuffer.allocate(124);
		int i = shortBuf.hashCode();
		System.out.println("Before writing content the "
				+ "current hash code of buffer : " + i);
		shortBuf.put((short) 2222);
		shortBuf.flip();
		int i1 = shortBuf.hashCode();
		System.out.println("After writing content the "
				+ "current hash code of buffer : " + i1);
	}
}