Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I always wondered how programming would be if we hadn't designed the assignment operator to be consistent with mathematics, and instead had it go LHS -> RHS, i.e. you perform the operation and then decide its destination, much like Unix pipes.


Plenty of LTR languages to choose from, especially concatenative languages like Forth, Joy, or Factor.

The APL family is similarly consistent, except RTL.


TI-BASIC is like this with its store operator →. I always liked it.

    10→A
    A+10→C


It also has an = operator, which saves the whole expression. It re-evaluates it then every time it was used.


Yep, CAS right in the BASIC on the 89 and up is a truly magical experience


For function calls too? List the arguments then the function's name?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: