The Artima Developer Community
Sponsored Link

Java Answers Forum
Phone Array

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
JayN

Posts: 2
Nickname: jayn
Registered: Dec, 2002

Phone Array Posted: Dec 8, 2002 6:49 PM
Reply to this message Reply
Advertisement
I have a project where I need to create a phone array. The array will create 100 phone numbers from 0000 to 0099.

After I have created the array, I need to simulate a telephone conversation between two randomly selected phones. If the phone being called to is in use, it will ring busy. This needs to similate an actual phone. When the phone is picked up, the boolean value of isBusy will be TRUE. The Conversation also needs to have a random call duration assigned using a Math.random command.

The following is the output.

Creating Phones...
0000
.
.
.
0099

Phone 0001 is calling Phone 0034
Conversation: Phone 0001 and Phone 0034
Conversation Lasted 4 Minutes
Phone 0001 Hangs Up
Phone 0034 Hangs Up

Any help would be greatly appreciated.

Topic: sms functionality Previous Topic   Next Topic Topic: How to fill a JPanel with points

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use