|
Quote: degree in mathmatics. He also loves VB That's OK. Mathmaticians, Madmaticians can actually love VB. On the other hand, proper Mathematicians can only distaste it.
|
|
|
|
|
So you say that there are several distinct sorts of eggheads?
I have lived with several Zen masters - all of them were cats.
His last invention was an evil Lasagna. It didn't kill anyone, and it actually tasted pretty good.
|
|
|
|
|
I see you don't like mathematics people.
|
|
|
|
|
Nah, I just don't want to be assimilated and become an egghead myself.
I have lived with several Zen masters - all of them were cats.
His last invention was an evil Lasagna. It didn't kill anyone, and it actually tasted pretty good.
|
|
|
|
|
I'm sure Star Fleet used Functional Programming and that's why they thought Ceti Alpha Five was Six.
Just thinkin outloud.
Jack of all trades, master of none, though often times better than master of one.
|
|
|
|
|
I'm a Programmer, I use functions in my code all the time. Tada!
- I would love to change the world, but they won’t give me the source code.
|
|
|
|
|
Functional programming preceeded OOP. OOP is (I think) a better idea.
Turbo Pascal started out as a functional language.
Fortran is a fucntional lanugage.
C is a functional language.
Javascript is not functional, but it is a functional language.
Visual Basic was a functional language.
My problem with the sudden interest (by people who don't matter) in functional programming is that everyone thinks OOP should be abandoned, or that functional crap should be injected into the OOP paradigm. These people are, for lack of a better term, retards.
|
|
|
|
|
From Wikipedia:
In computer science, functional programming is a programming paradigm—a style of building the structure and elements of computer programs—that treats computation as the evaluation of mathematical functions and avoids changing-state and mutable data. It is a declarative programming paradigm in that programming is done with expressions or declarations instead of statements. Functional code is idempotent: a function's return value depends only on its arguments, so calling a function with the same value for an argument always produces the same result. This is in contrast to imperative programming where, in addition to a function's arguments, global program state can affect a function's resulting value. Eliminating side effects, that is, changes in state that do not depend on the function inputs, can make understanding a program easier, which is one of the key motivations for the development of functional programming.
Fortran and C are not functional programming languages. Having functions does not make a language functional.
And one of the reasons for renewed interest in functional languages is they have certain advantages when trying to parallelize programs.
|
|
|
|
|
Sounds like "static methods" are a step in the "functional" direction then. And enumerators.
The Master said, 'Am I indeed possessed of knowledge? I am not knowing. But if a mean person, who appears quite empty-like, ask anything of me, I set it forth from one end to the other, and exhaust it.'
― Confucian Analects
|
|
|
|
|
From what you wrote, it sounds like the use of deterministic and non-deterministic functions. How does functional programming differ from traditional OOP where the developer knows they are writing a deterministic or non-deterministic function within a class?
|
|
|
|
|
Deterministic function always return the same value from the same input.
That is not the same as a function having no side effects.
|
|
|
|
|
Isn't it just what we used to do back in the UNIX days? String several hundred commands together with pipes and redirects and wonder why the script was so hard to debug.
Whenever you find yourself on the side of the majority, it is time to pause and reflect. - Mark Twain
|
|
|
|
|
I've thought about this same thing myself quite a bit.
OOAD (OOP) is a tool.
Functional Programming is a tool.
Most of the time you read things about how one tool or the other solves all problems.
But that is the same as thinking that a hammer solves all problems.
There are concepts from both things that can make your code better.
OOP / OOAD is really a way of organizing your code. It is not really more than that. But authors had to write books and those books had to meet a minimum length of pages so it exploded!
Functional Programming (FP) did the same thing: exploded in publication.
But again, Functional Programming contains some concepts that are novel and helpful.
The one big concept from FP is the idea of "No Side Effects".
Managing state while concurrent processes are running is a challenge.
FP has exploded because concurrent processing has exploded in hardware.
Suddenly you need a way to guarantee that you're not overwriting what another "thread" of execution is doing.
So, as we consider Foundational Concepts of programming paradigms we see that the two (OOP and FP) can be very useful together. One for organizing your code. The other for managing state in a concurrent environment.
Here's a very nice article I just googled that talks about Core Functional Programming Concepts[^]
|
|
|
|
|
Quote: FP has exploded because concurrent processing has exploded in hardware.
Suddenly you need a way to guarantee that you're not overwriting what another "thread" of execution is doing.
How is this any different than writing multithreaded code where the developer knows the scope of the variables used? I use the Task Parallel Library in .NET a lot, and never have any trouble with one thread/task affecting variables in another.
|
|
|
|
|
It’s not necessarily a whole lot different. Functional programming “automatically” supports structures and methods that support this type of thing a bit more easily than procedural or OOP languages. It’s also a way of thinking that is a part of FP.
And, you can definitely do the same things with different tools. That is what confuses newer devs the most, I think. Of course some languages and some language types make certain things harder or easier.
|
|
|
|
|
I've always had the impression that functional programming was academia's pathetic attempt to wrest computing back to the 1960's era notion of high priests in attendance upon their gods, with the academics in the role of the priests.
They can't earn a living doing programming themselves, so they're trying to keep the rest of us from doing so as well. them.
Software Zen: delete this;
|
|
|
|
|
F# works quite well with the rest of .NET, so it gets along well with OOAD,
It's a native .Net language and interesting to play with.
The first step in learning effective F# is to forget everything you know about programming unless you learned Prolog!
Learned Prolog, way back when Borland had a Prolog compiler and IDE, I found F# was similar in some respects with OOP added on.
CQ de W5ALT
Walt Fair, Jr.PhD P. E.
Comport Computing
Specializing in Technical Engineering Software
|
|
|
|
|
|
Tried to get into "real" FP a couple times but I haven't found a single tutorial starting with something FP does better than, let's say, OOP or even procedural. On the other hand, functional concepts are creeping into languages like C# where I've been using them extensively. Heck, even variable.dosomething(parm).dosomethingelse(someotherparm) is, as a matter of fact, functional.
|
|
|
|
|
The difference is OOAD is for the pragmatic real world. Functional programing is for the theoretical.
ok maybe not 100% true, just seems that way!
|
|
|
|
|
Language Vb.net and C# have Linq which provides these OOP languages with FP. Switching from a OOP language to an FP language is another mater. I keep saying my next project I'll write in F#. but my designs always wind up using OOP constructs so I stick with my OOP language and use all of its FP features.
|
|
|
|
|
Specifically I hate all of you who thought it would be a good idea to push an update - which I've been studiously ignoring because I know what will happen - without permission?
I use a set of documents - DOCX and XLSX - on a regular basis. For example, I keep "Thought of the day" as a DOCX file so I have a bunch ready to go, and can check that I aren't duplicating (too much)
So I pin them to the taskbar list.
And despite loads of reports from me and others who find it irritating, the Taskbar icons and their associated lists (both recent and pinned) are destroyed by your updates. Every. Single. Time.
That's irritating, but when I decide to go for an update, I can take a screenshot, and restore my lists after the update.
When you push a Elephanting update on me and don;t elephanting ask first I can't. So I lose them. Which is not just irritating, it's elephanting annoying. OK, I can work it out using folder contents and some of them via your "recent files" - but since DOCX and XLSX, OTT, ODT, and UncleTomCobley files are mixed in there without any care for the app that created them it doesn't help as much as it should.
Go and die in a fire.
Sent from my Amstrad PC 1640
Never throw anything away, Griff
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
I think your problem that you are using Windows... My LibreOffice haven't run a single update without my permission...
"The only place where Success comes before Work is in the dictionary." Vidal Sassoon, 1928 - 2012
|
|
|
|
|
Here, drink a Cuba-Libre[^] that will make you feel better
|
|
|
|
|
So it's true: even people who live in Heaven will find something to complain about.
Come and join us in the Hell that is ms office, for a few weeks; you'll soon change your tune.
I wanna be a eunuchs developer! Pass me a bread knife!
|
|
|
|