running multiple threads and multiple processes at the same time

From: Smegly (smegly_at_eftel.net.au)
Date: 05/17/04


Date: Tue, 18 May 2004 00:04:25 +0800

Hi,

I currently trying to implement a simulation banking system as part of an
assigment. I must stress i do not want line by line code to complete this,
what i'm really after is a guide to how i would go about doing this.

I need to read a customer from the file customer_list, into a fifo queue,
every Ts time. (where Ts is expressed in seconds).

Whilst this is happening i also need to have 3 tellers, who when a customer
enters the queues, a free teller grabs the customers and processes there
request, which takes Ts time. (as before). If no customer, teller sleeps.

>From thinking about this, I have come up what i believe is the best way to
go.

I think i should create one process that runs the customerInsert() routine,
and then three processes one for each teller ( running the Teller() routine)

Now, the problem that i have is i have never coded in C before. I am quite
well versed in Java, however. Therefore my first question is whats the best
way to start coding this? and secondly, how do i code this ?? Is there C
API DOCS like Java has ??

Thanks in advance,

Matt



Relevant Pages

  • RE: Disable Access to a printer
    ... purchases a cashier's check the teller then needs to produce one so turning ... customer twice in addition to waitng for the printer to warm up). ... The check printing pogram is started from a batch file if i could have ... HPPrinter and CheckPrinter. ...
    (microsoft.public.scripting.vbscript)
  • Re: Seen Elsewhere
    ... Customer: ?Then get your a** over here!? ... Teller: ?Ma?am, I have an illness that causes me mild tremors. ... really do have an illness there should be a sign over your window telling ... ?Now that would be discrimination, ...
    (uk.rec.sheds)
  • Re: OT "There you go"
    ... great idea to announce to everyone else in the bank how ... suppose to count the money out to the customer. ... teller windows and the people waiting in line. ...
    (rec.food.cooking)
  • Re: Banking question
    ... - Analysis of customer behaviour at the teller line and branch service ... Benchmarking of service point use and teller operation ... You should probably ask the source of the text for clarification, ... "analysis of customer behavour". ...
    (alt.usage.english)
  • Re: GIMUNZIP failure
    ... Many shops have multiple ... You can even order multiple java versions with ServerPac. ... the customer could be supporting multiple ...
    (bit.listserv.ibm-main)