Re: OFF-TOPIC: Algol 60 guru required

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 2009-08-04 at 01:58 +0400, Hiisi wrote:
> Dear All!
> Sorry for this off-topic, but I could not see any solution to my 
> problem. I'm trying to transform old Algol 60 program to C++. I can 
> understand every syntax of it except this construction:
> D(N+1):=N(N+2):=0.0;
> 
> Variables types:
> N - INTEGER
> D - REAL ARRAY
> What is it? How to represent in C++? Hope on this list there's people, 
> who could remember that from the time...
> Thanks in advance!

Something is very hokey here.  At first glance it looks like a double
assignment.  However Algol requires arrays to be specified and used with
square brackets.  So "D(N+1)" looks like it's meaningless since D is
declared to be an array; the form could be either a function or a
product, depending on how D is declared.  "N(N+1)" has to be a product.
But neither of them is an l-value -- they can't be assigned to.

There's a small example of Algol-60 at:
        http://en.wikipedia.org/wiki/Trabb_Pardo-Knuth_algorithm


-- 
fedora-list mailing list
fedora-list@xxxxxxxxxx
To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list
Guidelines: http://fedoraproject.org/wiki/Communicate/MailingListGuidelines

[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux