Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. The Lounge
  3. programming language statement order

programming language statement order

Scheduled Pinned Locked Moved The Lounge
functional
17 Posts 12 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Marc Clifton

    Jeffry J. Brickley wrote: he just opens everything and leaves it open for the duration.... Hey, I didn't know we worked for the same company! I just fixed that problem![^] :-D Marc MyXaml Advanced Unit Testing

    E Offline
    E Offline
    El Corazon
    wrote on last edited by
    #8

    Marc Clifton wrote: Hey, I didn't know we worked for the same company! I just fixed that problem![^] thank you very much for fixing that! hey... there were only 4 of us last week, when did they hire you? uhh... you aren't after my job are you? :~ _________________________ Asu no koto o ieba, tenjo de nezumi ga warau. Talk about things of tomorrow and the mice in the ceiling laugh. (Japanese Proverb)

    1 Reply Last reply
    0
    • A Asim N

      In a pure functional programming language statement order is irrelevant for program execution, i.e. you can change the order of the statements and the program will execute identically. Now what language features makes this possible and why it is not possible in imperative languages. Regards, Asim

      J Offline
      J Offline
      Jeff Bogan
      wrote on last edited by
      #9

      Agree I do. Order what matter does? Am completely I intelligible without myself worrying ordering about word.

      C M J D 4 Replies Last reply
      0
      • J Jeff Bogan

        Agree I do. Order what matter does? Am completely I intelligible without myself worrying ordering about word.

        C Offline
        C Offline
        Colin Angus Mackay
        wrote on last edited by
        #10

        a Actually, an arbitraty assigning could get if in interesting it ordering sentence start to words you. a I a a It me of to in so by the C++ all the that used work with that file that were than lengh header rather reminds ordered logical function grouping developer signature refactored signatures application


        Do you want to know more?


        Vogon Building and Loan advise that your planet is at risk if you do not keep up repayments on any mortgage secured upon it. Please remember that the force of gravity can go up as well as down.

        1 Reply Last reply
        0
        • J Jeff Bogan

          Agree I do. Order what matter does? Am completely I intelligible without myself worrying ordering about word.

          M Offline
          M Offline
          Marc Clifton
          wrote on last edited by
          #11

          Jeff Bogan wrote: Agree I do. Order what matter does? Am completely I intelligible without myself worrying ordering about word. Yes Yoda. May the order be with you! :-D Marc MyXaml Advanced Unit Testing

          1 Reply Last reply
          0
          • A Asim N

            In a pure functional programming language statement order is irrelevant for program execution, i.e. you can change the order of the statements and the program will execute identically. Now what language features makes this possible and why it is not possible in imperative languages. Regards, Asim

            J Offline
            J Offline
            Jorgen Sigvardsson
            wrote on last edited by
            #12

            Because the foundation of imperative languages are built upon the Von Neumann model, while functional languages aren't. Functional languages can be mapped onto imperative languages, but the inverse is not possible. For instance look at this imperative piece of code:

            x = 3;
            y = 3 * x;

            . Switching the order just won't work, because y depends on the value inside x. In a functional world, the code would simply state that x is 3, and y is whatever x is times three (and that can be done in any order). Imperative languages allows you to tell the computer what to do, while functional languages allows you to tell the computer how things are related. (And hopefully the machine will figure out what to do based on your description of the problem) -- Weiter, weiter, ins verderben. Wir müssen leben bis wir sterben.

            K 1 Reply Last reply
            0
            • J Jeff Bogan

              Agree I do. Order what matter does? Am completely I intelligible without myself worrying ordering about word.

              J Offline
              J Offline
              Jorgen Sigvardsson
              wrote on last edited by
              #13

              To make it more interesting, start with adjectives, follow up with nouns, continue with verbs, and lastly auxiliary verbs (if any). Adverbs? Just toss them out the window, they're just syntactic sugar anyway ;) -- Weiter, weiter, ins verderben. Wir müssen leben bis wir sterben.

              1 Reply Last reply
              0
              • J Jeff Bogan

                Agree I do. Order what matter does? Am completely I intelligible without myself worrying ordering about word.

                D Offline
                D Offline
                David Wulff
                wrote on last edited by
                #14

                Aoccdrnig to a rscheearch at Cmabrigde Uinervtisy, it deosn't mttaer inwaht oredr the ltteers in a wrod are, the olny iprmoetnt tihng is tahtthe frist and lsat ltteer be at the rghit pclae. The rset can be a total mses and you can sitll raed it wouthit any porbelm. Tihs is bcuseae the huamn mnid deos not raed ervey lteter by istlef, butthe wrod as a wlohe... ;) If you are interested[^]


                David Wulff The Royal Woofle Museum

                Everybody is entitled to my opinion

                1 Reply Last reply
                0
                • A Asim N

                  In a pure functional programming language statement order is irrelevant for program execution, i.e. you can change the order of the statements and the program will execute identically. Now what language features makes this possible and why it is not possible in imperative languages. Regards, Asim

                  R Offline
                  R Offline
                  Russell Morris
                  wrote on last edited by
                  #15

                  In a purely functional programming environment, no statement has any side effects: the most it can ever do is evaluate to a value. It cannot, under any circumstances, affect program state outside itself. This essentialy boils down into saying that functional langauges have only function-local scope variables, and all parameters are passed by-value, not by-reference. With these guards in place, it is guarunteed that the program state before a function x is called will be exactly the same as the program state immediately after function x returns (except, of course, for the return value of function x being stored). As a corollary, these conditions end up meaning that a function will always return the same value when given the same input. -- Russell Morris "So, broccoli, mother says you're good for me... but I'm afraid I'm no good for you!" - Stewy

                  1 Reply Last reply
                  0
                  • J Jorgen Sigvardsson

                    Because the foundation of imperative languages are built upon the Von Neumann model, while functional languages aren't. Functional languages can be mapped onto imperative languages, but the inverse is not possible. For instance look at this imperative piece of code:

                    x = 3;
                    y = 3 * x;

                    . Switching the order just won't work, because y depends on the value inside x. In a functional world, the code would simply state that x is 3, and y is whatever x is times three (and that can be done in any order). Imperative languages allows you to tell the computer what to do, while functional languages allows you to tell the computer how things are related. (And hopefully the machine will figure out what to do based on your description of the problem) -- Weiter, weiter, ins verderben. Wir müssen leben bis wir sterben.

                    K Offline
                    K Offline
                    KaRl
                    wrote on last edited by
                    #16

                    Never thought about a career in teaching? I think you perfectly answered his homework question :-D


                    Fold With Us! "A leader is a man who can adapt principles to circumstances - Georges S. Patton, 1885–1945"

                    J 1 Reply Last reply
                    0
                    • K KaRl

                      Never thought about a career in teaching? I think you perfectly answered his homework question :-D


                      Fold With Us! "A leader is a man who can adapt principles to circumstances - Georges S. Patton, 1885–1945"

                      J Offline
                      J Offline
                      Jorgen Sigvardsson
                      wrote on last edited by
                      #17

                      I wouldn't go back to teaching unless I'm given a big fat stack of cash every month. Teaching just ain't worth it otherwise. :) -- Weiter, weiter, ins verderben. Wir müssen leben bis wir sterben.

                      1 Reply Last reply
                      0
                      Reply
                      • Reply as topic
                      Log in to reply
                      • Oldest to Newest
                      • Newest to Oldest
                      • Most Votes


                      • Login

                      • Don't have an account? Register

                      • Login or register to search.
                      • First post
                        Last post
                      0
                      • Categories
                      • Recent
                      • Tags
                      • Popular
                      • World
                      • Users
                      • Groups