a few simple sample for java