added prototype code