function shipfest()
{
//Set up our vic-- er, characters.
var innocent_newbie = "Larfen J. Stocke, esq";
var experienced_oldbie = "Desdendelle";
//Set up the location.
var the_board = new Array();
//And keep a count of how much wild shipping has been going on
var hours_of_shipping = 0;
// Cycle through the Board clock hour by hour
for (clock_time = 0; clock_time < 24; clock_time++) {
//Des seems to be around from 7 am to 7pm
//So put him on
if (clock_time == 7)
{
the_board.push(experienced_oldbie);
}
//And take him off
else if (clock_time == 19)
{
for (board_count = 0; board_count {
if (the_board[board_count] == experienced_oldbie)
{
delete the_board[board_count];
}
}
}
//Larfen is up from Board-midnight to about 5, then from 8pm to midnight.
//So two ons
if (clock_time == 0)
{
the_board.push(innocent_newbie);
}
else if (clock_time == 20)
{
the_board.push(innocent_newbie);
}
//And one off
else if (clock_time == 5)
{
for (board_count = 0; board_count {
if (the_board[board_count] == innocent_newbie)
{
delete the_board[board_count];
}
}
}
//If both Des and Larfen are around, shipping can occur.
for (des_checker = 0; des_checker < 24; des_checker++) {
if (the_board[des_checker] == experienced_oldbie)
{
for (larfen_checker = 0; larfen_checker < 24; larfen_checker++) {
if (the_board[larfen_checker] == innocent_newbie)
{
hours_of_shipping += 1;
}
}
}
}
}
//And print out a popup of how much shipping has gone on.
window.alert(hours_of_shipping);
//The tragic conclusion:
//The love of Desdendelle and Larfen J. Stocke, esq is doomed
//because they're never around at the same time.
}