Hello Tim,

Wednesday, December 17, 2003, 8:01:14 PM, you wrote:


TJ> * Konstantin Knizhnik <[EMAIL PROTECTED]> [031217 07:26]:
>> 
>> 
>> Rebol has awful implementation of hash tables.
>> First of all, it is very inconvenient that there are normal set/get
>> operations. You have to use something like this:
>> 
>>    h: find/tail hash key
>>    either h [change h key value] [append append hash key value]
>> 
>> instead of
>> 
>>    hash[key] = value
 
TJ>   Grrr! I *hate* doing that, and in python I have to do
TJ>   it a lot!
TJ>   In rebol, I just do

TJ>     hash/que 'val key

TJ>   much nicer, it took me half a day to implement
TJ>   my own object, but it was well worth it.

Do not forget to say "from my point of view..."
I think that a lot of other people will consider "hash[key] = value"
syntax much clearer and simpler than "hash/que 'val key".
But it is a matter of taste and so can not be discussed - somebody like
red color, somebody - black. It is waste of time to discuss which
color is better. In Python you can also define your own class and do
everything you like in it. But associative array (dictionary, hash
table) is fundamental data structure and if high level language has
no such builtin or standard library structure - it is not advantage of
this language.

>> in most other high-level languages.

TJ>   All language have their strengths and weaknesses, *and* their "best
TJ>   fits".

Yes, all attempts to create some "best" universal language are
failed. Each language has its own advantages and its own domain.

TJ>   Mysql is a best fit for rebol IMHO, rebol mysql access on our large,
TJ>   multi-language projects beats perl and python hands down both
TJ>   in access speed and in impelementation/coding.

MySQL is certainly best solution when you are implementing some server
application. But even in this case DyBASE has some advantages:
- efficient transaction mechanism
- transparent object loading and storing (I hope you do will not say that
packing/unpacking data from relational database is "nicer" than...
lack of packing/unpacking).

But DyBASE is positioned for another kind of applications - which
needs embedded database engine. If your application needs to store
some data between sessions, you will not include MySQL in
distribution, will you? And require user to setup, configure and
administrate it.

So, as well as programming languages, DyBASE has its own niche.

TJ> One of Rebol's strengths
TJ>   is TCP/IP is native (compiled into the binray)
TJ>   and the mysql-protocol exploits that splendidly.

Hmm, and in which language TCP/IP is not native?
All of them sooner or later will have to invoke system OS function to access 
sockets,...


TJ>   On the other hand, perhaps the native 'hash' of rebol is not is
TJ>   advanced as the btree approach that python uses.
TJ>   I do believe that a true hash datatype is a linked list,
TJ>   though.

TJ>   still, it is nice to see these tests and the work that you've
TJ>   done.

TJ>   regards
TJ>   tim



-- 
Best regards,
 Konstantin                            mailto:[EMAIL PROTECTED]

-- 
To unsubscribe from this list, just send an email to
[EMAIL PROTECTED] with unsubscribe as the subject.

Reply via email to