I was trying to do my computer science homework but I am stuck as I was trying to use the following methods.
public Graphics create(int x,int y,int width
You can go through the java tutorial for 2D graphics and javadocs if not done already.