Posted on
September 9th, 2008 0 Comments
Shows the OS statistics and information about OS.
/*******************************************************
* MYCPLUS Sample Code - http://www.mycplus.com *
* *
* This code is made available as a service to our *
* visitors and is provided strictly for the *
* purpose of illustration....
Read More |
Make a Comment
Posted on
September 9th, 2008 0 Comments
An object of type MovingBall holds data about a “ball” that has a color, radius, position, speed, and direction. The ball is restricted to moving around inside a rectangle in the xy-plane. The ball can draw itself in a graphics context and will move when it is told to move. This class uses some trigonometry and vector math in its implementation.
/*******************************************************
*...
Read More |
Make a Comment
Posted on
September 9th, 2008 0 Comments
This applet simulates a network chat, in which the user chats with someone over a network. Here, there is no network. The partner is simulated by a thread that emits strings at random. The point of the simulation is to show how to use a separate thread for receiving information.
The applet has an input box where the user enters messages. When the user presses...
Read More |
Make a Comment
Posted on
September 9th, 2008 0 Comments
A simple applet that displays information about mouse events as they occur. Since double-buffering is not used, the display flickers quite a bit.
/*******************************************************
* MYCPLUS Sample Code - http://www.mycplus.com *
* *
* This code is made available as a service...
Read More |
Make a Comment
Posted on
September 9th, 2008 0 Comments
This applet solves the Towers of Hanoi problem for a tower of 10 disks. (Ten differntly-sized disks are stacked in a pile, in order of decreasing size. There are two other places for piles. The object is to move the pile to the second available place, subject to the rules that only one disk at a time can be moved, and no disk can be piled on top of a smaller...
Read More |
Make a Comment
Posted on
September 9th, 2008 0 Comments
Stars Applet that show some stars on the applet windows.
/*******************************************************
* MYCPLUS Sample Code - http://www.mycplus.com *
* *
* This code is made available as a service to our *
* visitors and is provided strictly for the *
* purpose...
Read More |
Make a Comment
Posted on
September 9th, 2008 0 Comments
This applet demonstrates recursion by counting the number of squares in a “blob”. The squares are arranged in a grid, and each position in the grid can be either empty or filled. A blob is defined to be a filled square and any square that can be reached from that square by moving horizontally or vertically to other filled squares. This applet fills...
Read More |
Make a Comment
Posted on
September 9th, 2008 0 Comments
A simple applet that shows labels with six different types of border.
/*******************************************************
* MYCPLUS Sample Code - http://www.mycplus.com *
* *
* This code is made available as a service to our *
* visitors and is provided strictly for the *
* ...
Read More |
Make a Comment