Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9302061
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T23:10:11+00:00 2026-06-18T23:10:11+00:00

In my program there are some users and their clients. I have the list

  • 0

In my program there are some users and their clients.
I have the list of users and their associated clients.

Example

U1 -> c1, c2, c3, c5, c8, c10, c12
U2 -> c3, c5, c13, c8, c12, c14
U3 -> C2, C5, c8, c11, c12, c14
..
...
....
.....
and many more.

some clients are common in user’s list.

I want to make reverse hierarchy of clients to users .
If any update comes for any client then it will goes to only those users for which the client is associated.

Please suggest me which data structure should be used map, multimap, boost::bimap, multiset

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-18T23:10:12+00:00Added an answer on June 18, 2026 at 11:10 pm

    Perhaps this is a use case for a Boost.Bimap where both keys are multisets, and an entry in the bimap represents a single connection between a user and the client. So for the following setup

    U1 -> C1 C2 C3
    U2 -> C4 C1
    U3 -> C5 C1
    

    you would have entries (U1, C1), (U1, C2), (U1, C3), (U2, C4), (U2, C1), (U3, C5) and (U3, C1).

    You can traverse both keys in their order, i.e. U1, U1, U1, U2, U3 on the left and C1, C1, C1, C2, C3, C4, C5 on the right. (Note how both sides contain repeated entries!)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a program, and in that program there is some variables (username and
I have a program where there is a master/slave setup, and I have some
My program needs to know when a user ejects cd disc. Is there some
I came across a C++ program for my use, in which there was some
I'm developing a program that makes some floating points calculations. Is there any way
Google analytics posted on their blog about an example Java program to extract data
I have a program that users are using that will take a file from
Hello All I am writing some software that will allow users to create their
I have some flash banners for an affiliate program. On my own sites I
I have a rich client program installed on users PCs where I want to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.