Print

Print


On Sun, Sep 14, 2014 at 05:32:32AM -0400, Dana Nutter wrote:
> On 9/13/14 10:43 PM, Logan Streondj wrote:
> > On Sun, Sep 14, 2014 at 12:06:38AM +0300, Risto Kupsala wrote:
> >> 13.9.2014 13:57, Logan Streondj wrote:
> >>> this is equivalent to C VSO style
> >>> int beep = 23;
> >>> beep += 4;
> >>> printf("%i",beep);
> >>
> >> I don't detect any VSO order.
> >>
> >> Operators are verbs so these lines have SVO order.
> >> int beep = 23; // Integer beep is 23.
> >> beep += 4; // Beep grows by 4.
> >>
> >> The last line begins with a verb but there's no subject. It reminds
> >> me of the imperative voice.
> >> printf("%i",beep); //Print a text string with integer called beep!
> >>
> >> Object oriented style in C++ uses SVO order. For example:
> >> printer.print(beep); //The printer prints the beep.
> >
> > hmmm yes, svo is  a good way of describing it.
> 
> Ah but what about how some earlier languages used LET or SET to do
> assignments?
> 
> The default word order of human langauge is defined by the
> indicative mood.  With a computer language everything is in the
> imperative. Even some human languages put imperatives as VSO as in
> French or Spanish.

Good point, 
you must be familiar with imperative programming,
where everything is indeed an imperative statement,
also it's "child" object oriented programming is likewise.

The main competing programming paradigm, is functional programming,
which as you mentioned use let statements a lot. 
Based on my research, the future is functional,
because functional programming is more compatible with parallel
architectures, such as those found in graphics cards, and multiple
core processors. 

Pure functional programming languages don't allow mutation of
variables. However they do tend to make everything a dense
mathematical formula. i.e. in Haskell

type declaration:
factorial :: (Integral a) => a -> a

mkaw english:
suj factorial be word of function for integer alpha that suj alpha to alpha ya

colloquial english:
factorial is a function that for any integer type alpha can accept an
alpha as input, and will then produce an alpha as output.


serially:
factorial n | n < 2 = 1
factorial n = n * factorial (n - 1)

mkaw english:
suj factorial for case suj input be start of function ya
if input less-than 2 then to 1 ya
else to that obj input be multiply by that be factorial suj that 
                obj 1 be subtract from input ya 

colloquial english:
factorial is a function whose subject variable is called input starts here.
if input is less than 2 then return 1.
else return input multiplied by the factorial of 1 subtracted from input.


parallel friendly:
factorial n = foldl1 (*) [1..n]

mkaw english:
suj factorial for case suj input be start of function ya
to that be accumulate by multiply obj that 
        be sequential list from 1 till input ya

colloquial english:
factorial is a function whose subject variable is called input starts here.
return the accumulation of multiplication being applied to the
elements of a sequential list from 1 to input.

or simply (to show we normally are parallel processors ourselves):

mkaw english:
factorial for integer alpha by that be multiply obj 
        that be sequence from natural 1 til alpha ya

colloquial english:
factorial a number by multiplying all natural numbers from one til it.

Anyways ya, I'm sure colloquial english is easier to understand,
however the mkaw english I at least have a hope of parsing easily by
computer, and it is regular enough that could get used to it I think.