[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Help-smalltalk] Bag printString behavior
From: |
montgomery f. tidwell |
Subject: |
[Help-smalltalk] Bag printString behavior |
Date: |
Tue, 05 Dec 2000 12:35:24 -0800 |
Howdy,
i've noticed that when you send printString to a Bag it
returns each element and the number of occurrences of that
element within the Bag.
|b|
b := Bag new.
b addAll: #('11' '22' '33' '11')
Transcript show: b printString; cr.
output is: Bag('11':2 '22':1 '33':1 )
i checked Squeak and VWNC and neither of them show the
occurrences in the output.
Squeak: a Bag('11' '11' '22' '33')
VWNC: Bag('11' '11' '22' '33')
shouldn't the result of printString be like the others??
\\//_
- [Help-smalltalk] Bag printString behavior,
montgomery f. tidwell <=