Computer SW Languages OCAML - Berkeley CSUA MOTD
Berkeley CSUA MOTD:Computer:SW:Languages:OCAML:
Berkeley CSUA MOTD
 
WIKI | FAQ | Tech FAQ
http://csua.com/feed/
2024/12/24 [General] UID:1000 Activity:popular
12/24   

2008/7/28-8/5 [Computer/SW/Languages/Python, Computer/SW/Languages/Functional, Computer/SW/Languages/OCAML] UID:50704 Activity:nil
7/28    So, I'd like to try playing with a functional language.  Any
        recommendations?
        \_ Haskel.  Why would you start with anything else?
        \_ Haskell if you want a _functional_ language.  Ocaml if you want to
           see what a proper language implementation looks like.  LISP if
           you want old fogies to think you are cool. -- ilyas
        \_ Haskell.  Why would you start with anything else?
           \_ I don't know.  I've heard Erlang has been used more in industry.
              (Isn't Google using it for something?)  I don't really know
              the differences.
              the differences.  Sisal was for scientific computing, which is
              the area I work in.  F# includes OOP (but I'd rather work in
              Linux.)
              \_ Are you learning this to learn or are you learning it to
                 get industry experiance?  If the second I'd say spend your
                 time elsewhere.  Haskell is one of those languages where once
                 you start to understand how to actually use it this light
                 will come on in your brain and suddenly you will never see
                 programming in quite the same light.  Erlang is cool, but
                 has a lot less support library support/people out there
                 messing with it, so actually trying to do anything with
                 it is hard.  OCaml is pretty damn cool as well, but really,
                 if you want to wrap your head around pure functional
                 programming, the language you should start with is Haskell.
                 Oh, and you want this book: http://www.haskell.org/soe
                 \_ Oh, and another thing.  Haskell is also good because it
                    makes it really hard to cheat and do things in a non
                    functional manner.  Its purity is its strength.
                    \_ Ah, that's a good point. -op
                 \_ Well, mostly I would just like to learn about functional
                    programming to learn.  But I generally like languages I
                    learn to be useful for something as well, otherwise I
                    never get to use it.  For example, I like Ruby better than
                    Python, and learned it to learn it.  However, everything at
                    work uses Python, so now I've forgotten most of the Ruby.
                    Thanks for the book ref.
                    \_ Really learning Haskell will make you a much better
                       programmer, even if you never use it for anything.
                       It really forces you to relearn a lot of things in
                       ways you probably never even considered, and once you
                       finish bashing your head against it and it starts
                       making sense you will be a much stronger coder.
2024/12/24 [General] UID:1000 Activity:popular
12/24   

2004/9/9-10 [Computer/SW/Languages/OCAML, Computer/SW/Languages/Perl] UID:33448 Activity:high
9/9     Why are there so much politics on the motd? Isn't this the
        CSUA? Doesn't the C stands for something computer??
        \_ Its stands for Computer Stuff and Unrelated Arguing
           \_ Golf clap.
              \_ I didn't know there even was such a thing as a golf ho,
                 and you're telling me they've got their own VD's?
        \_ Yeah, let's talk about computer, or girls!!
        \_ When someone says something stupid, I feel I must succinctly show
           them the error of their ways, or at least show other reasonable
           people.  Oh well, I'll just let stupid people keep thinking that
           way.
        \_ The CSUA as an organization doesn't manage or have anything to do
           with the contents of motd.public. Politics get discussed so often
           because it's one of those things that never ends. You never finish
           the argument. And unlike more esoteric subjects for debate,
           politics is something that anybody and everybody feels qualified to
           participate in. Politics is always in the news. Other things show
           up on motd many times but nothing more than politics. Or Perl.
           \_ Hey, I would talk about programming languages, but not a lot
              of people care.  P.S. Perl is morally wrong. -- ilyas
                               \_ Methinks he doth protest too much.  --dbushong
                                  \_ SILENCE, SINNER!
                               \_ what do you think of ocaml?
                                  \_ Ocaml is a language built around a type
                                     inference system, and I think that's like
                                     the tail wagging the dog.  The bar for
                                     languages is set so low that if people
                                     see something with lambdas that's fast
                                     they get excited.  It shouldn't be that
                                     way. -- ilyas
                                     \_ Have you ever looked over Java?  I've
                                        generally found the structure of the
                                        language really presents itself for
                                        large SE projects.  The string
                                        manipulation elements built directly
                                        into the language are pretty awesome
                                        also -- they really cut down on the
                                        dev cycle, I've found.
        \_ Pontification is preferable to work.
        \_ it wasn't like this from 1980s till the late 90s, when the
           failed jobless laid-off dotcomers got bitter and started to rant.
           \_ Obviously someone who doesn't remember the bitterness of
              joblessness of the early 90s...
2004/5/20-21 [Computer/SW/Languages/C_Cplusplus, Computer/SW/Languages/OCAML] UID:30334 Activity:insanely high
5/20    I have seen some ocaml comments on the motd.  What about Haskell?
        Is it better/worse/about the same?  I know it is supposed to "pure"
        but don't know what this translates to in reality.
        \_ Haskell is the only language I want to know something about, yet
           know almost nothing about.  I know it's not speedy, unlike ocaml,
           but has lots of clean ideas, and you can write really short code in
           it.  Haskell is a 'pure functional language' in that it allows no
           sideeffects.
           Haskell programmers use something called 'monadic programming' to
           get around this (say when doing IO).  Another way out is to use
           something called 'uniqueness typing' which is what Clean does.
           Personally I think insisting on a pure functional language is silly.
             -- ilyas
           \_ What value are these languages outside of theory and academia?
              \_ Troll attempt noted and appreciated. -- ilyas
                 \_ "Trolls are anyone that disagrees with you," a motd
                    person, circa May 2004
                    \_ You are right, it was a thoughtprovoking question.
                         -- ilyas
                        \_ I was actually quite serious you self righteous
                           bastard.  You're always going off about all these
                           obscure little languages and I actually really
                           wanted to know what use they are outside academia
                           but frankly I don't give a damn now.   If you don't
                           know or don't want to bother explaining then just
                           don't.  I certainly wasn't trolling.  --bite me
                 \_ This is a legit. question. What exactly is it that makes
                    this language (and/or any other language you keep talking
                    about on the motd) much better than C? I've looked up
                    things like ocaml and such, but they just seem like ya
                    syntax to learn w/o any added benefit (the resulting code
                    doesn't look any easier to write/debug/maintain than C).
                    Its not that I have anything against learning new prog.
                    langs (I've been working on ObjC to do Cocoa/OSX stuff),
                    its just that I want to know what the real benefit is
                    of these non-C-like langs that you keep mentioning.
                    \_ Well, I can't answer this for you.  _I_ find that GC
                       languages with good libraries infinitely easier to
                       get work done in than C.  YMMV.  Prolog is one of those
                       languages where if you are solving the right problem
                       the solution is 10 lines, and would have been 300 lines
                       in pretty much anything else (not a made up example).
                       Prolog also has fast implementations, since there's a
                       good mapping between prolog code and C.  Also, I agree
                       with Dijkstra in that poking with new languages can
                       teach you about programming, so it's certainly good to
                       learn other languages just for that reason, even if you
                       don't plan to use them in practice. -- ilyas
                       \_ The only benefits of C are: there's a C compiler for
                          nearly every platform--okay there's only 1 benefit.
                          GC is a non-issue really, and I've seen as many
                          problems with GC as without.  But yes, an important
                          reason to learn many languages is that some concepts
                          are easier to implement in different languages, hence
                          you actually think about doing things differently.
                          It's better to have many tools in the box than to
                          have a reeeeally good hammer. -emarkp
           \_ Is there something in the language itself that dispose it to
              slower implementation or just nobody bothers to make the effort?
              \_ Troll attempt noted and appreciated.  -- ilyas #8 fan
              \_ I don't know about Haskell.  Ocaml is about as fast as gcc
                 compiled C.  Does that answer your question? -- ilyas
2004/5/11-12 [Computer/SW/Languages/OCAML, Computer/SW/Languages/Functional] UID:30169 Activity:very high
5/11    To FP activists on the motd, if currying is such a great idea, why
        it's not implemented symmetrically in say Caml?  It seems more
        natural to treat the arguments of a function more symmetrically.
        \_ If by 'symmetric' you mean that if, for example, I have a function
           f of two arguments a and b, I should be able to curry on either
           a or b, then Ocaml does this using labeled arguments.  Caml does
           not since it's meant to be a 'minimalist' language. -- ilyas
           not since it's meant to be a 'minimalist' language.  In conclusion,
           RIDE BULLET TRAIN!  USE OCAML!  -- ilyas
           \_ I am looking at it.  So far so disappointed.
              \_ I think most people who have been programming for a while
                 have gotten past the 'perfect language' disease.  I would be
                 happy to address specific questions you might have.  Or better
                 yet email me, or drop by #csua. -- ilyas
                 \_ I am not through with the reading yet, so I could be wrong.
                    So far, my complaint is the following: (1) rather bad
                    grammar in general.  (2) The use of capitalization and
                    special characters to signify different kinds of
                    identifiers at the language level.  (3) Field name in
                    record has file scope.  (4) If typing is such an important
                    aspect of it, it might as well make it optional to be
                    dynamic, same with patterns.  (5) Data structure does not
                    feel as flexible as it could be.  One might as well think
                    it is C and implemnt cons using record.  (6) I am not sure
                    how ref works, but I certainly miss pointers.  Overall,
                    it seems to be somewhere in the middle from C, Scheme, and
                    maybe Prolog.
                    \_ (1) People complain about the syntax.  It doesn't
                       bother me.  If it bothers you, Ocaml comes with a
                       syntax redefinition tool called camlp4 -- you can
                       change the ENTIRE syntax if you want.
                       \_ You can write preprocessors to make Fortran look
                          Lisp, Lisp look like Perl, Perl look like Basic,
                          Basic look like C, and C look like Fortran.
                       (2) This is because the language is 'rich.'  Perl does
                       the same thing.  I don't really know a better way.
                       What Ocaml has is better than throwing gobs of parens
                       at the problem like lisp does.  In other words, too
                       much syntax is better than too little.
                       \_ ruby i think is as powerful as perl yet has
                          a very clean syntax, without $ % and bare filehandles
                             it's as fast as it sounds. -- ilyas
                          etc.  -someone else
                          \_ It's true that ruby is clean, but this comes with
                             a price.  Everything in ruby is an object, and
                             it's as fast as it sounds.  The other thing about
                             ruby is that it's dynamically typed, so you need
                             to distinguish less things at compile time --
                             this translates into a lot less syntax.  Naturally,
                             dynamic typing makes things slow, also. -- ilyas
                             \_ No it doesn't. You are wrong on both accounts,
                                here. There are implementation techniques
                                to make pure object-oriented languages and
                                dynamically typed languages perform very
                                fast.
                                \_ Sure it does.  You may make it better than
                                   what ruby has (no hard accomplishment since
                                   ruby has possibly the slowest implementation
                                   of any language), but you will not be able to
                                   beat a statically typed language because
                                   the compiler simply has less information.
                                   OO is useful, but ruby makes everything an
                                   object, which is convenient but those virtual
                                   function calls do add up.  Anyways, if
                                   someone writes a fast ruby compiler, it will
                                   make me happy, ruby is a neat language.  A
                                   good thing to ponder, if you ever go to the
                                   'great language shootout' page, is why the
                                   fastest languages there are either C or
                                   statically typed.  -- ilyas
                                   \_ You are just wrong here. YMWTG
                                      polymorphic inline cache, or Cecil
                                      \_ Read what I said again.  I would be
                                         happy to look at some benchmarks of
                                         Cecil or Self.  Self is neat. -- ilyas
                                         \_ Stop being condecending. I wasn't
                                            referring to your complaints about
                                            the Ruby interpreter, but to
                                            your general statements about
                                            dynamically typed and pure OO
                                            languages. Virtual Machines
                                            have access to all the type
                                            information that was available
                                            statically, and in the case of
                                            some type systems, more. With
                                            that info, the VM and generate
                                            type-specific code, in-line away
                                            virtual functions, usw.
                       \_ I think it's more to shift the burdern from the
                          parser and compiler to the user.  Perl is not a
                          model for good design.
                       (3) Yes, I don't like that.  There are deeper problems
                       with structs and typing.
                         \_ I guess that labels of variant and records are
                            internally represented as integers.  I would be
                            nice to be able to access them directly.  Array
                            type should have the option of specify size,
                            both for efficiency and type checking.
                       (4) I don't understand your reasoning here.  Typing
                       in Ocaml makes me really happy because it catches bugs
                       for me, and because I know how to get around it if I
                       need to (Obj.magic).
                       \_ I am not saying typing is a bad idea.  But it would
                          be nice to have the option (1) to turn it off for
                          some variables or some types and (2) to delay some
                          typing until runtime and (3) go (not so much) further
                          make type a type that one can modifies and manipulate
                          in runtime.  The same goes for pattern.  There will
                          conceptual problems involved, but they are worth the
                          reward.  Plus, most of the logic underlying is
                          already present in the compiler and just need to
                          be incorporated in the runtime, if called for by
                          the program.
                       (5) Don't understand what you are trying to say.  Did
                       you notice the object system too, and functors?  Is the
                       stdlib bad?  What couldn't you find that you would find
                       in another stdlib?
                       \_ sorry, haven't got to the object system yet, but
                          generally I feel that a language should either
                          provide very elementary data structure that allows
                          one to describe arbitrary complex ones with relative
                          ease or provide so many high level data structures
                          that it is hard to ask more.  C and Lisp are
                          examples of the former, while custom programing
                          language (Maple, Mathematica, etc) falls with the
                          latter.  OCaml seems to be in the middle, which is
                          annoying.  For example, I haven't seen a set type,
                          which of course can be implemented with tuple.  But
                          it is not easy to implement efficiently, unless you
                          employs tricks that seem to defeat many OCaml
                          principles.  Again, I could be just ignorant of some
                          of the powers of ocaml.
                       (6) If you really want, you can play with pointers using
                       Obj.magic (again), but you probably don't need them.
                       Very few people these days need pointers (actual integer
                       values) over references (names referring to objects) in
                       practice.  -- ilyas
                       \_ somehow I couldn't find documentation for Obj.magic
                          but it sounds like something bad that if you use all
                          the time, you might as well use another language.
2003/12/8-9 [Computer/SW/Languages/OCAML] UID:11353 Activity:kinda low
12/7    Learning OCAML. What the ****[fuck] is with the syntax? It seems like
        these people made a more creative pass at the Intercal concept.
        \_ What's this used for anyway? Looks like something dumped on the
           world by the French.
        \_ (a) It grows on you, trust me
           (b) You can redefine the entire syntax if you don't like it
               using ocamlp4
                 -- ilyas
           \_ No it doesn't. Most people don't have as much growing
              on them as you do, ilyas.
2001/8/26-27 [Computer/SW/Languages/OCAML] UID:22265 Activity:moderate
8/26    ocaml or modula-3?
        \_ sliced babies, squirrelstumper
        \_ Ocaml is pretty good if you don't need access to machine pointers.
        \_ ocaml for the runtime optimizer.
        \_ neither.  why?
2001/7/20 [Computer/SW/Languages/OCAML] UID:21883 Activity:insanely high 50%like:20755 66%like:21142 57%like:22189 57%like:22388 57%like:22881 50%like:23262 57%like:36306
7/19    Motd poll:  I want
        sex:
        love:.
        neither:
        Chocolate: .
        to get into grad school: .
        wife with big bosom and hot body: ..
        girlfriend (wives are bad) with big bosom and hot body: .
        yermom: .
        a girlfriend with a hot body who likes Ocaml: .
        \_ girlfriends try to become wives. Concubines are the
           way to go.
        yermom: .
        a girlfriend with a hot body who likes Ocaml: .
        \_ OCAML!  OCAML!  OCAML is the STANDARD!  Programming language.
        a hot prof in grad school: .
        kinney to STFU: ...
        \_ did kinney take a vacation between 7/1 and 7/16? i thought i might
           have missed some from between there. the sheer volume of spew from
           the man is hilarious.
        fully tricked atlon mp system: .
        fully tricked g4 mp system: .
        fully tricked us3 mp system: .
2024/12/24 [General] UID:1000 Activity:popular
12/24   
Berkeley CSUA MOTD:Computer:SW:Languages:OCAML:
.