473,413 Members | 1,801 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,413 software developers and data experts.

Sets - Bit Array Vs. List

Hello All:
What is the difference between these two. Is there any site that can show me
the contrast and similarities between both of these? I have a couple of
begginer books that make no reference on this issue. Please help. Thanks in
advance.

Sonoman

Jul 19 '05 #1
3 5735

Sonoman <fc*****@REMOVEspunge.org> wrote in message
news:2O*******************@fe03.atl2.webusenet.com ...
Hello All:
What is the difference between these two.
The standard library features a container type
called 'std::list'. The same is not true of
'bit array' (perhaps you meant something else?)
Is there any site that can show me
the contrast and similarities between both of these?
The standard library has a 'list' type, but not a
'bit array' type. Do you mean the 'std::bitset'
type?

If so, look in any programming or algorithms book
which should show you the difference between an
array and a linked list.
I have a couple of
begginer books that make no reference on this issue.
Which books?
Please help.


Peer reviews of C++ books can be viewed at
www.accu.org

-Mike

Jul 19 '05 #2

"Sonoman" <fc*****@REMOVEspunge.org> wrote in message
news:2O*******************@fe03.atl2.webusenet.com ...
Hello All:
What is the difference between these two. Is there any site that can show me the contrast and similarities between both of these? I have a couple of
begginer books that make no reference on this issue. Please help. Thanks in advance.

Sonoman


You asking about the implementation of sets using either arrays of bits or
lists? Not really a C++ question.

The obvious difference it that you can only implement sets whose members are
chosen from a finite range of integral values using a bit array. You
couldn't have a set of words implemented as a bit array for instance, but a
list of strings would be possible. There are also efficiency differences
between the two.

Of course the C++ answer is to use neither, use std::set instead, (or even
std::bitset) that's what its for.

john
Jul 19 '05 #3
C++ how to program by Deitel & Deitel, C++ in 21 days 2nd edition by Jesse
Liberty, but these two do not have much that I can use. BUT I just borrowed
from a friend The C++ programming Language by Stroustroup. I glanced at it
and it looks very promising. I just hope it does not go over my head! It
looks at lot more advanced that the other two.

Sonoman
"Mike Wahler" <mk******@mkwahler.net> wrote in message
news:bg**********@slb0.atl.mindspring.net...

Sonoman <fc*****@REMOVEspunge.org> wrote in message
news:2O*******************@fe03.atl2.webusenet.com ...
Hello All:
What is the difference between these two.


The standard library features a container type
called 'std::list'. The same is not true of
'bit array' (perhaps you meant something else?)
Is there any site that can show me
the contrast and similarities between both of these?


The standard library has a 'list' type, but not a
'bit array' type. Do you mean the 'std::bitset'
type?

If so, look in any programming or algorithms book
which should show you the difference between an
array and a linked list.
I have a couple of
begginer books that make no reference on this issue.


Which books?
Please help.


Peer reviews of C++ books can be viewed at
www.accu.org

-Mike


Jul 19 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: Steve | last post by:
This post has two parts. First is my feedback on sets. (Hello? Last summer called, they want their discussion thread back...) Second is some questions about my implementation of a partition...
15
by: les_ander | last post by:
Hi, I have many set objects some of which can contain same group of object while others can be subset of the other. Given a list of sets, I need to get a list of unique sets such that non of the...
2
by: Phil | last post by:
Hello, Yet another question I'm afraid. I'm trying to construct a two dimensional array of sets (9 X 9). The first line of code gives me a single array of nine sets and the second line is my...
6
by: John Henry | last post by:
Hi list, If I have a bunch of sets: a = set((1, 2, 3)) b = set((2, 3)) c = set((1, 3)) ..... What's the cleanest way to say:
11
by: Prateek | last post by:
I have 3 variable length lists of sets. I need to find the common elements in each list (across sets) really really quickly. Here is some sample code: # Doesn't make sense to union the sets -...
1
by: JosAH | last post by:
Greetings, Introduction This week I'll write a bit about generics (those funny angular brackets). I need an example and decided to use sets and some of their operations. This weeks' article...
6
by: happyhondje | last post by:
Hello everyone, I've got a little issue, both programming and performance-wise. I have a set, containing objects that refer to other sets. For example, in a simple notation: (<a, b, c>, <d, e>)...
6
by: Patrick Sullivan | last post by:
Hello. I will be using some large data sets ("points" from 2 to 12 variables) and would like to use one class for each point rather than a list or dictionary. I imagine this is terribly...
20
by: Mr.SpOOn | last post by:
Hi, I need a structure to represent a set of integers. I also need to perform on this set some basic set operations, such as adding or removing elements, joining with other sets and checking for...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.