Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: Java multithreading
how we do he coding of agent
 
in multi agent environment, specifically for air line reservation.
Posted 3-Feb-13 21:03pm
Comments
Richard MacCutchan at 4-Feb-13 5:02am
   
This is not a valid question, you need to provide more specific details of your problem.
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

I have implemented agent based systems in the past. The principle I have worked to is that there are three levels, Manager, Agent and Worker.
 
The Manager receives all the requests and ensures they are passed to the correct Agent then passes the replies back to the callers. Simple and easily defined responsibility, can't go too wrong there.
The Agent maintains a FIFO queue of requests and has one or more Workers to manage the work load. When a Worker is free, it receives a new request.
The Workers process the individual requests. This is the only part of the system that changes for different types.
 
Simple, effective and very expandable. Look out in the coming months and there will be an article on this if I ever get it finished.
  Permalink  
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

#include<iostream.h>
using namespace std;
 
int main() {
  int x, y;
  cout<<"what is your height?"<<"\nyour feet: ";
  cin>>x;
  cout<<"your inches: ";
  cin>>y;
  cout<<"your height is: "<<x<<"'"<<" and "<<y<<"''";
  cout<<"\nYou are tall!";
 
  return 0;
}
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 495
1 Maciej Los 340
2 Richard MacCutchan 265
3 BillWoodruff 225
4 Mathew Soji 200
0 OriginalGriff 8,804
1 Sergey Alexandrovich Kryukov 7,457
2 DamithSL 5,689
3 Maciej Los 5,279
4 Manas Bhardwaj 4,986


Advertise | Privacy | Mobile
Web04 | 2.8.1411028.1 | Last Updated 4 Feb 2013
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100